#include <iostream>
using namespace std;
const int MAX= 100 ;
int memo[MAX];
int fib(int n)
{
if(n<=1) return n;
if(memo[n] != 0) return memo[n];
return memo[n] = fib(n-1) + fib(n-2);
}
int main()
{
int n;
while(cin>>n)
cout<<fib(n)<<endl;
return 0;
}