三位数反转-题解(C语言代码) 摘要:#include int main() { int num, a = 0, b = 0, c = 0; scanf("%d", &num); a = num / 100; b = …… 题解列表 2019年09月27日 0 点赞 0 评论 657 浏览 评分:0.0
1866: 三位数反转 摘要:解题思路:切片注意事项:参考代码:while True: try: a = input() print(a[::-1]) except: brea…… 题解列表 2024年12月26日 0 点赞 0 评论 295 浏览 评分:0.0
三位数反转 (C语言代码) 摘要:解题思路:注意事项:参考代码:#include<iostream>#include<algorithm>using namespace std;int main(){ int a,b,c,n; …… 题解列表 2018年09月25日 5 点赞 0 评论 1411 浏览 评分:0.0
三位数反转 (C语言代码) 摘要:解题思路: 输入三位数,分离出它的百位、十位和个位,反转后输出注意事项: 1.有多组输入数据 &nbs 题解列表 2018年09月28日 0 点赞 0 评论 837 浏览 评分:0.0
三位数反转 (C语言代码) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int i,j,k,n; while(scanf("%d",&n)!=EOF) { w…… 题解列表 2019年01月08日 0 点赞 0 评论 684 浏览 评分:0.0
三位数反转-题解(C++代码) 摘要:# 细节 多组输入数据。 分离出来的个位、十位、百位数字,直接输出。 不要计算逆序后的值再输出,会丢失低位的 0 。比如 500。 # 代码 ```cpp #include int…… 题解列表 2020年01月04日 0 点赞 0 评论 536 浏览 评分:2.0
三位数反转 (C语言代码) 摘要:解题思路:注意事项:输出数必须分离,否则错。参考代码:#include<stdio.h>int main(){ int x,i,a,b,c; while((i = scanf("%d",&x))!= …… 题解列表 2019年02月13日 0 点赞 0 评论 936 浏览 评分:2.0
三位数反转-题解(Python代码) 摘要:这道题可以通过取巧的方式来解答 直接当做字符串来反转即可 也不用考虑100反转后要输出001的问题 代码如下: ```python n = str(input()) while 1: …… 题解列表 2020年03月21日 0 点赞 0 评论 821 浏览 评分:4.4
三位数反转-题解(C++代码) 摘要:不会的小伙伴来看看哦,答案错50%的也来看看。 首先注意看题目,输入一个三位数,分离出它的百位、十位和个位,反转后输出。(有多组输入数据),这个很重要,可以用while 循环输入,while(cin…… 题解列表 2020年01月31日 0 点赞 3 评论 707 浏览 评分:5.1
三位数反转 (C语言代码) 摘要:解题思路:用字符串保存直接反输出注意事项:直接输出printf("%c%c%c",s[2],s[1],s[0]);是错误的 因为输入两位数的时候,s[2]是'\0'了参考代码:#in…… 题解列表 2018年07月26日 1 点赞 0 评论 1526 浏览 评分:6.0