| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 65423 | 万正钰 | PELL数列 | C++ | Runtime Error | 1 MS | 276 KB | 411 | 2024-01-25 16:11:03 |
#include<algorithm> #include<iostream> #include<cstring> #include<cmath> #include<iomanip> using namespace std; int main(){ int a[1000],b[1000]={1,2},n,m,ans=0; cin>>m; for(int i=2;i<=1000;i++){ b[i]=2*b[i-1]+b[i-2]; } for(int i=1;i<=m;i++) cin>>a[i]; for(int i=1;i<=m;i++){ cout<<b[a[i]-1]%32767<<endl; } return 0; }
Runtime Error:Segmentation fault