题解 1119: C语言训练-"水仙花数"问题1

来看看其他人写的题解吧!要先自己动手做才会有提高哦! 
返回题目 | 我来写题解

筛选

无聊的星期六

摘要:解题思路:注意事项:参考代码:x=input() if int(x)==sum(((int(x[i])**3) for i in range(3))):     print(1) else: ……

课本上的习题

摘要:参考代码:#include<iostream> #include<cmath> using namespace std; int main() { int x; cin >> x;……

C语言--好理解

摘要:解题思路:简单的if语句的使用;注意事项:用pow(n,m)表示立方,不然只有75分。pow(n,m)代表n的m次方;参考代码:#include <stdio.h>int main(){    int……

C语言训练-"水仙花数"问题1

摘要:解题思路:注意事项:参考代码:#include <stdio.h>int main() {    int number;    int originalNumber, remainder, resul……

三位数的水仙花数

摘要:解题思路:把每位数拿出来,然后判断是不是对的注意事项:参考代码:#include<stdio.h>int main(){    int i,a,b,c;    scanf("%d",&i);//输入三……

if语句解决水仙花数问题

摘要:参考代码:#include <stdio.h>#include <math.h>int main(){    int n;    scanf("%d",&n);    if(n>99&&n<1000)……

C语言训练-"水仙花数"问题1

摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){    int a,b,c,i;    bool p;    cin>>……

水仙花数-for循环

摘要:解题思路:注意事项:  经历for循环之后n的值会变化参考代码:    #include<iostream> using namespace std; int main() {         i……

水仙花数问题1

摘要:解题思路:注意事项:参考代码: public class Main { public static void main(String[] args) {        Scanner sc = new……