Run ID:164836
提交时间:2026-11-07 15:33:55
#include<iostream> // cin\cout\endl #include<cstdio> //scanf()\printf() #include<cstring> // strcpy()\strcat()\strcmp()\strlen()\memset() #include<cmath> //sqrt()\pow()\abs()\ceil()\floor()\max()\min() using namespace std; int main(){ int a=1,b=1,c,k; cin>>k; if(k==1||k==2) cout<<1; for(int i=3;i<=k;i++) {c=a+b; a=b; b=c; } cout<<b; return 0; }