提交时间:2023-11-27 13:57:19

运行 ID: 112633

#include<bits/stdc++.h> using namespace std; #define int long long int a[1919810]; signed main(){ int n; cin >> n; a[1] = 1; a[0] = 1; for(int i = 2 ; i <= n ; i++) a[i] = a[i - 1] + a[i - 2]; cout << a[n] << endl; return 0; }