初学者用if暴力解法 摘要:解题思路:定义一个变量a,其中:if条件a/10000!=0表示a为一个五位数,以此类推注意事项:注意else if 的用法,不要丢了else 第二个问题不要用else参考代码:#include <s…… 题解列表 2023年11月22日 0 点赞 0 评论 258 浏览 评分:0.0
[编程入门]数字的处理与判断 摘要:a = input()print(len(a))b = list(a)for i in b: print(i,end=' ')print()print(a[::-1])…… 题解列表 2023年11月23日 0 点赞 0 评论 314 浏览 评分:0.0
C++利用指针重复遍历输出 摘要:解题思路:注意事项:参考代码:#include<iostream>#include<string.h>using namespace std;int main(){ char str[20] =…… 题解列表 2023年12月21日 0 点赞 0 评论 221 浏览 评分:0.0
递归函数法 摘要:解题思路:注意事项:参考代码:#include <stdio.h>#include <math.h>int b[5],i=0,mask2=1,n=0;int fun(int a ,int w){ if…… 题解列表 2023年12月21日 0 点赞 0 评论 214 浏览 评分:0.0
1009: [编程入门]数字的处理与判断 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ int num = 0; cin >> num; s…… 题解列表 2024年01月23日 0 点赞 0 评论 531 浏览 评分:0.0
输出数字位数,并按位输出,再逆序输出。 摘要:解题思路:注意事项:参考代码:void main(){ int a; int i=0,divisor = 10; int array[5]; int trunNum = 0; …… 题解列表 2024年01月31日 0 点赞 0 评论 257 浏览 评分:0.0
求最大公约数和最小公倍数 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ int m, n,min=1,max=1,i; cin >…… 题解列表 2024年02月08日 0 点赞 0 评论 741 浏览 评分:0.0
C++速度功成 摘要:解题思路:将输入的数字串当作数组,利用库函数string,直接获得数组长度,然后for循环遍历数组每一个位置上的数字,输出;法二:构建一空数组,利用for循环将输入的数字串逐个拆解,从个位数依次填入数…… 题解列表 2024年03月13日 0 点赞 0 评论 328 浏览 评分:0.0
C语言 注意范围 摘要:解题思路:注意事项:参考代码:#include <stdio.h> //头文件#include <string.h>int main() //一个文件的开头{ char n[6]; gets(n);…… 题解列表 2024年03月16日 0 点赞 0 评论 450 浏览 评分:0.0
【编程入门】数字的处理和判断 摘要:解题思路:注意事项:参考代码:#include <stdio.h> #include <string.h> int main() { char a[10]; int i,we…… 题解列表 2024年04月17日 0 点赞 0 评论 491 浏览 评分:0.0