[编程入门]自定义函数之字符串反转 摘要:解题思路:因为要倒序这个字符串,所以我们可以把他当做倒序输出注意事项:注意是从s.length()-1开始,到i>=0结束参考代码:#include<bits/stdc++.h> using nam…… 题解列表 2022年05月09日 0 点赞 0 评论 185 浏览 评分:0.0
编写题解 1031: [编程入门]自定义函数之字符串反转(利用切片解决) 摘要:解题思路:注意事项:参考代码:def main(): a = input() print(a[::-1])main()…… 题解列表 2022年05月08日 0 点赞 0 评论 210 浏览 评分:0.0
用数组与for循环解题 摘要:解题思路:注意事项:参考代码:#include <stdio.h>#define N 100void oppo(char sz[],int m){ int j; for(j=m-1;j>=0;j--)…… 题解列表 2022年05月07日 0 点赞 0 评论 175 浏览 评分:0.0
[编程入门]自定义函数之字符串反转(函数版) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>#include<string.h>int i;char T1(){ char a[100]; gets(a);int n=…… 题解列表 2022年05月06日 0 点赞 0 评论 234 浏览 评分:0.0
自定义函数之字符串反转 摘要:原题链接:[编程入门]自定义函数之字符串反转解题思路:其实跟数字的反转是一样的,倒叙输出就可以了注意事项:参考代码:#include <stdio.h>#include <stdlib.h>#incl…… 题解列表 2022年05月06日 0 点赞 0 评论 164 浏览 评分:0.0
[编程入门]自定义函数之字符串反转 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;string s;int main(){ cin>>s; for(int i=…… 题解列表 2022年05月06日 0 点赞 0 评论 162 浏览 评分:0.0
C语言程序设计题目小解 摘要:解题思路:简单注意事项:无参考代码:#include<stdio.h>#include<string.h> int exchange(char a[],char b[]){ int i,l,j …… 题解列表 2022年05月04日 0 点赞 0 评论 301 浏览 评分:9.9
根据题意定义函数来逆序输出 摘要:解题思路:注意事项:不考虑空格情况,如有需要,加个strip就行了参考代码:def revers(n): m=n[::-1] return mdef main(): n=input(…… 题解列表 2022年04月26日 0 点赞 0 评论 148 浏览 评分:0.0
编程入门]自定义函数之字符串反转(经典做法,建议收藏!!!) 摘要:解题思路:从后往前进行遍历输出。注意事项:一定要注意倒叙便利的范围!!!参考代码:#include<stdio.h>#include<string.h>void def(char *a){ //运用…… 题解列表 2022年04月24日 0 点赞 0 评论 508 浏览 评分:7.0
1031: [编程入门]自定义函数之字符串反转(C++) 摘要:解题思路:注意事项:参考代码:#include<iostream> #include<cstring> using namespace std; int reverse(char a[], …… 题解列表 2022年04月16日 0 点赞 0 评论 195 浏览 评分:6.0