多余的string函数 摘要:解题思路:#include<stdio.h> #include<string.h> int main(void) { char a[100]; gets(a); i…… 题解列表 2024年12月28日 2 点赞 0 评论 750 浏览 评分:0.0
极简[编程入门]自定义函数之字符串反转 摘要:解题思路:无注意事项:无参考代码:s = input()print([s::-1]…… 题解列表 2025年01月10日 1 点赞 0 评论 810 浏览 评分:0.0
自定义函数之字符串反转 摘要:解题思路: 使用getchar( )获取字符; 使用putcahr( )显示字符;注意事项: 输入一个字符串的首地址,可以…… 题解列表 2025年03月07日 1 点赞 0 评论 1272 浏览 评分:0.0
暴力解法--一行代码搞定 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ string s; …… 题解列表 2025年03月17日 2 点赞 0 评论 879 浏览 评分:0.0
编写题解 1031: [编程入门]自定义函数之字符串反转 摘要: #include #include #include #include #include using namespace std;…… 题解列表 2025年04月03日 1 点赞 0 评论 1404 浏览 评分:0.0
反向遍历法 摘要:解题思路:先保存,后逆向输出注意事项:处理换行符:fgets 会把输入的回车 \n 一起读入字符串,必须用 str[strcspn(str, "\n")] = '\0…… 题解列表 2026年04月02日 0 点赞 0 评论 235 浏览 评分:0.0
全面严谨的字符串反转写法 摘要:解题思路:这个题目,我看了很多人的题解,只是简单的对半交换位置输出。这样的代码是不严谨的,题目说了输出不包含空格,所以要把空格去掉,剩下来的临时数组逆序输出。同时严谨代码还要把末尾可能有的换行符给去掉…… 题解列表 2026年07月19日 0 点赞 0 评论 21 浏览 评分:0.0