1031: [编程入门]自定义函数之字符串反转 【c++】 摘要:解题思路:用string 类型来解决 并用下标访问 循环逆序打出字符串注意事项: 为了方便没有定义一个函数 就写了主函数参考代码:#include<iostream>#include<string>u…… 题解列表 2023年01月05日 0 点赞 0 评论 564 浏览 评分:9.9
自定义函数之字符串反转(除了hellow word 外简单的代码) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>#include<string.h>int main(){ char str[100]; gets(str); int n = strl…… 题解列表 2023年02月09日 0 点赞 0 评论 136 浏览 评分:9.9
031: [编程入门]自定义函数之字符串反转 摘要:```cpp #include #include #include using namespace std; // 写一函数,使输入的一个字符串按反序存放, // 在主函数中输入并输出反序…… 题解列表 2023年02月23日 0 点赞 1 评论 190 浏览 评分:9.9
C程序字符串反轉(100字符內) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>#include<string.h> void function_1(char *a,char *b,int len_1);//函數聲明…… 题解列表 2023年03月26日 0 点赞 0 评论 126 浏览 评分:9.9
自定义函数之字符串反转-题解 摘要:定义数组-输入字符串-获取字符串个数-字符串倒置赋给另一数组-将字符的后面一位赋'\0'作为结束标志-输出 ```c int main() { char arr[100],brr[100…… 题解列表 2023年03月30日 0 点赞 0 评论 141 浏览 评分:9.9
自定义函数之字符串反转java 摘要:解题思路:注意事项:参考代码:import java.util.Scanner;public class Main { public static void main(String[] args…… 题解列表 2023年04月08日 0 点赞 0 评论 136 浏览 评分:9.9
自定义函数之字符串反转 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;int main(){ char a[1000]; cin>>a; for(int …… 题解列表 2023年05月16日 0 点赞 0 评论 177 浏览 评分:9.9
自定义函数之字符串反转 摘要:解题思路:这段代码中的mystrrev函数用于反转输入的字符串。在这个函数中,参数ch1被当作字符数组的指针来处理。当数组作为参数传递给函数时,实际上传递的是数组的地址,也就是指向数组第一个元素的指针…… 题解列表 2023年11月08日 0 点赞 0 评论 149 浏览 评分:9.9
自定义函数之字符串反转 摘要:解题思路:b[i] = a[len - i - 1]注意事项:strlen()函数(统计字符串长度)要有头文件#include <string.h>参考代码:#include <stdio.h>#in…… 题解列表 2023年11月08日 0 点赞 0 评论 146 浏览 评分:9.9
用循环来倒置字符串 摘要:解题思路:注意事项:参考代码:import java.util.ArrayList;import java.util.List;import java.util.Scanner;public clas…… 题解列表 2023年11月14日 0 点赞 0 评论 122 浏览 评分:9.9