'commit'
This commit is contained in:
16
TangDou/XiTi/1181.cpp
Normal file
16
TangDou/XiTi/1181.cpp
Normal file
@@ -0,0 +1,16 @@
|
||||
#include <bits/stdc++.h>
|
||||
|
||||
using namespace std;
|
||||
|
||||
int f(int n) {
|
||||
if (n == 1) return 1;
|
||||
if (n == 2) return 2;
|
||||
return dp(n - 1) + dp(n - 2);
|
||||
}
|
||||
|
||||
int main() {
|
||||
int N;
|
||||
cin >> N;
|
||||
cout << dp(N) << endl;
|
||||
return 0;
|
||||
}
|
||||
Reference in New Issue
Block a user