1016-水仙花数判断 语言:C++ 摘要:解题思路:注意事项:参考代码:#include<iostream>#include<cmath>using namespace std;int main(){ int a,b,c=3; …… 题解列表 2022年10月04日 0 点赞 0 评论 432 浏览 评分:0.0
水仙花数判断 摘要: #include using namespace std; int main() { int a, b, c; for (int i = …… 题解列表 2022年10月10日 0 点赞 0 评论 324 浏览 评分:0.0
题目 1016: [编程入门]水仙花数判断—常规求解方法 摘要:解题思路:while循环注意事项:指数用pow函数或者其他形式参考代码:#include<stdio.h> #include<math.h> int main(void) { int i…… 题解列表 2022年10月21日 0 点赞 0 评论 524 浏览 评分:0.0
编写题解 1016: [编程入门]水仙花数判断 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int a,b,c,i; for(i=100;i<=999;i++) { a=i/100; b=i/10%1…… 题解列表 2022年11月23日 0 点赞 0 评论 334 浏览 评分:0.0
水仙花数的判断 摘要:解题思路:获取个位数:对数字取模于10获得个位数(%10)获取十位数:先整除10得到两位数(/10)再取模于10得到十位(%10)获取百位数:直接整除于100;注意事项:参考代码:#include<i…… 题解列表 2022年12月14日 0 点赞 0 评论 489 浏览 评分:0.0
新手常规简易 摘要:解题思路:常规注意事项:参考代码:#include<stdio.h>int main(){ int num=100; int a,b,c; for(num==100;(99<num)…… 题解列表 2022年12月23日 0 点赞 0 评论 392 浏览 评分:0.0
1016: [编程入门]水仙花数判断 稍稍复杂的循环判断 摘要:解题思路:就是简单循环判断题的加强版,设置范围,然后循环就好了。注意事项:参考代码:for i in range(100,1000): string=str(i) a=string[0] …… 题解列表 2022年12月29日 0 点赞 0 评论 482 浏览 评分:0.0
编写题解 1016: [编程入门]水仙花数判断 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main() { int x,y,z; for(int a=100; a<1000; …… 题解列表 2023年01月06日 0 点赞 0 评论 352 浏览 评分:0.0
编写题解 1016: [编程入门]水仙花数判断 摘要:解题思路:注意事项:参考代码:for i in range(100,1000): if i == pow(int(str(i)[0]),3)+pow(int(str(i)[1]),3)+p…… 题解列表 2023年02月18日 0 点赞 0 评论 448 浏览 评分:0.0
水仙花数判断 摘要:解题思路:int类型数据取值时不是四舍五入,是直接舍去小数点后的位,利用这个性质分别可以得到各个位上的值注意事项:参考代码:#include <stdio.h>#include <math.h>int…… 题解列表 2023年02月25日 0 点赞 0 评论 556 浏览 评分:0.0