Run ID 作者 问题 语言 测评结果 时间 内存 代码长度 提交时间
77216 sh25_shenpy Pell数列 C++ 通过 0 MS 248 KB 275 2025-12-21 16:41:10

Tests(1/1):


#include<bits/stdc++.h> using namespace std; int pell(int n){ if(n<3) return n; else return 2*pell(n-1)+pell(n-2); } int main(){ int n,g; cin>>n; for(int i=1;i<=n;++i){ cin>>g; cout<<pell(g)%32767<<endl; } return 0; }


测评信息: