求平方和-题解(C语言代码) 摘要:解题思路:看代码注意事项:参考代码: #include <stdio.h> int main() { int j,k; scanf("%d%d",&j,&k); …… 题解列表 2020年11月28日 0 点赞 3 评论 1480 浏览 评分:9.9
求平方和-题解(C语言代码) 摘要:解题思路:输入2个整数,求两数的平方和并输出。这题涉及到加法和乘法运算,当然,也有pow函数求平方的方法可以解答。我们这里先讲最新手的办法。注意事项:参考代码:#include<stdio.h>int…… 题解列表 2020年10月22日 0 点赞 0 评论 875 浏览 评分:0.0
求平方和-题解(C语言代码) 摘要:解题思路:一种是直接a*a+b*b,还有一种是用数学函数pow(a,2)+pow(b,2)注意事项:当用数学函数时不要忘记头文件#include<math.h>参考代码:#include<stdio.…… 题解列表 2020年08月28日 0 点赞 4 评论 3135 浏览 评分:9.9
求平方和-题解(C语言代码) 摘要:解题思路:平方可想到用这2种方法:直接计算平方或用pow()函数注意事项:如果用pow()记得加入头文件math.h,但该题直接计算即可。参考代码:#include<stdio.h>int main(…… 题解列表 2020年08月28日 0 点赞 0 评论 1693 浏览 评分:9.5
求平方和-题解(C语言代码)简单到爆 摘要:解题思路:建三个变量:a、b、sum。注意事项:sum最好归零,不然可能会bug。具体代码如下↓参考代码:#include<stdio.h>int main(){ int a,b,sum=0; …… 题解列表 2020年08月13日 0 点赞 0 评论 1103 浏览 评分:6.0
求平方和-题解(C语言代码) 摘要:#includeint main(){ int a=0,b=0,sum=0; scanf("%d%d",&a,&b;); sum=a*a+b*b; printf("%d",su…… 题解列表 2020年08月06日 0 点赞 1 评论 564 浏览 评分:6.0
求平方和-题解(C语言代码) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(void){ int a,b; scanf("%d%d",&a,&b); printf("%d\n",a*a+b*b)…… 题解列表 2020年08月03日 0 点赞 0 评论 678 浏览 评分:0.0
求平方和-题解(C语言代码) 摘要:参考代码:#include<stdio.h> int main() { int a, b; a = b = 0; scanf("%d %d",&a,&b); printf("%…… 题解列表 2020年07月22日 0 点赞 4 评论 2272 浏览 评分:8.4
求平方和-题解(C语言代码) 摘要:解题思路: 本题只需用scanf()函数获取两个数(A和B),再用printf()函数输出两数的平方和即可。 注意事项: scanf()函数中的&不要忘记输。 参考代码: ```c …… 题解列表 2020年07月04日 0 点赞 0 评论 1445 浏览 评分:9.1
求平方和-题解(C语言代码) 摘要:```c #include int main() { int a=0,b=0,c=0; scanf("%d %d",&a,&b); c=(a*a)+(b*b); …… 题解列表 2020年03月24日 0 点赞 0 评论 856 浏览 评分:0.0