Badstr

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
#include <stdio.h>
#include <iostream>
using namespace std;
long long fib(int n) {
long long f1, f2, f3;
f1=f2=f3=1;
for(int i=2; i<n; i++) {
f3=f2;
f2=f1;
f1=f2+f3;
}
return f1;
}
int main() {
freopen("badstr.in", "r", stdin);
freopen("badstr.out", "w", stdout);
int c;
cin>>c;
cout<<fib(c*2+2);
return 0;
}