#include<bits/stdc++.h> using namespace std; const int N=10010; int a[N]; int main() { int n; cin>>n; a[1]=0,a[2]=1; for(int i=3;i<=n;i++) { a[i]=a[i-1]+a[i-2]; } cout<<a[n]; return 0; }
''' ma,klncjvqfh'ofdwpxkla knsdjgvr3p2etqwfklsc,;vm dnbwepvgqfr'mcl EA$VKPJkfo[qe a'vmdrbwjo[5htwrml;DVBRWwwwwwwgm;sdddddd Rbwgpppppppppppppppppppppppppppppppppppppppppppppppppppppsjbfm fj rrrrrrrrrrrrrrrrrrr
#include<bits/stdc++.h> using namespace std; int f(int x){ if(x==1) return 0; if(x==2) return 1; return f(x-1)+f(x-2); } int main() { int n; cin>>n; cout<<f(n); return 0; }
有好心人发个题解码
Using your lizikid universal account