- C++
间谍风云题解
- 2024-7-12 11:59:12 @
# 至于解析······自己理解
#include<bits/stdc++.h>
using namespace std;
long long int fd[51];
int main(){
int n;
cin>>n;
for(int i=2;i<=n+1;i++) cin>>fd[i];
for(int i=2;i<=n+1;i++) fd[i]+=fd[i-1]+fd[i-2];
for(int i=2;i<=n+1;i++) cout<<fd[i]<<endl;
return 0;
}
2 条评论
-
lubingyu LV 9 @ 2024-8-10 14:22:14
没过
-
2024-7-17 14:31:03@
666
- 1