#include <iostream>
using namespace std;
/* run this program using the console pauser or add your own getch, system("pause") or input loop */
int main(int argc, char** argv) {
int n;
int a[46]={1,1}; //因為 n<=45 從 0~45 共 46 個
for(int i=2;i<46;i++)
a[i]=a[i-2]+a[i-1];
while(cin>>n)
cout<<a[n]<<endl;
return 0;
}