题解 1015: [编程入门]求和训练

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

筛选

[编程入门]求和训练;使用一个循环求和

摘要:解题思路:找出三个数中的最大值,然后循环最大的那一个循环,使用判断来决定是否需要计入求和参考代码:#include <stdio.h> // 求以下三数的和,保留2位小数 1~a之和 1~b的平……

[编程入门]求和训练

摘要:a, b, c = map(int, input().strip().split())Sum = 0Sum += (a+1)*a/2for i in range(1, b+1):    Sum += ……

1015: [编程入门]求和训练

摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;int main(){    double a,b,c,d=0,e=0,f=0,Sn……

[编程入门]求和训练

摘要:解题思路:注意事项:参考代码:a,b,c = map(int,input().split())sum_1 = 0sum_2 = 0sum_3 = 0for i in range(1,a+1):    ……

[编程入门]求和训练

摘要:```python a,b,c = map(int,input().split()) seq_a = [i for i in range(1,a+1)] seq_b = [i**2 for ……

[编程入门]求和训练

摘要:参考代码:#include<stdio.h> #include<math.h> int main() { int a,b,c; int a1=0,b1=0; float c1=0,s……