1018: [编程入门]有规律的数列求和 摘要:import java.io.*; /** * 规律:第一项的分母是 1,分子是 2,往后分母是前一项的分子,分子是前一项的分子加上分母。 */ public class Main…… 题解列表 2022年05月11日 0 点赞 0 评论 155 浏览 评分:0.0
不知道写啥 摘要:解题思路:把分母和分子拆开看注意事项:保留小数点后两位,注意定义类型参考代码:#include<iostream>#include<cmath>#include<iomanip>using names…… 题解列表 2022年05月11日 0 点赞 0 评论 159 浏览 评分:0.0
有规律的数列求和 摘要:解题思路:找数列的规律。注意事项:做除法运算,分子和分母是浮点数!参考代码:#include<stdio.h>int main() { int n; double s=0,x=1.0,y=2.…… 题解列表 2022年05月16日 0 点赞 0 评论 89 浏览 评分:0.0
1018: [编程入门]有规律的数列求和 摘要:#include<stdio.h> int main() { float a=2.0,b=1.0,sum=0.0,j,k; int n; scanf("%d",&n); for(int i…… 题解列表 2022年06月06日 0 点赞 0 评论 162 浏览 评分:0.0
编写题解 1018: [编程入门]有规律的数列求和-递归 摘要:解题思路:注意事项:参考代码:n=int(input())f1=1f2=2s=f2/f1for i in range(2,n+1): f1,f2=f2,f1+f2 s=s+f2/f1pri…… 题解列表 2022年06月16日 0 点赞 0 评论 280 浏览 评分:0.0
题解 1018: [编程入门]有规律的数列求和(C语言) 摘要:解题思路:1.将每个分数表示出来2.相加求和注意事项:注意变量数据类型,及输出格式。参考代码:#include<stdio.h> int main(void){ float i,m; …… 题解列表 2022年07月24日 0 点赞 0 评论 204 浏览 评分:0.0
编写题解 1018: [编程入门]有规律的数列求和 摘要:解题思路:注意事项:参考代码:#include<stdio.h> int main() { double a = 1, b = 2, x = 0, y = 0; double term…… 题解列表 2022年07月30日 0 点赞 0 评论 115 浏览 评分:0.0
有规律的数列求和 摘要:解题思路:注意事项:参考代码:#include<iostream>#include<iomanip>using namespace std;int main(){ int n; cin>>…… 题解列表 2022年08月10日 0 点赞 0 评论 141 浏览 评分:0.0
有规律的数列求和 摘要:# 有规律的数列求和c++代码实现 ### 解题思路: **通过观察,可发现一个数列:** **1 2 3 5 8 13 21** **像这种前两项相加等于第三项的数列叫做“斐波那…… 题解列表 2022年08月25日 0 点赞 0 评论 210 浏览 评分:0.0
编写题解 1018: [编程入门]有规律的数列求和 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int N; float sum=0; float sum1=0; scanf("%d"…… 题解列表 2022年08月31日 0 点赞 0 评论 509 浏览 评分:0.0