#include<iostream>
using namespace std;

int main(){
  int n,f[45];
  cin >> n;
  f[0]=1;
  f[1]=1;
  for(int i = 2; i <=n; i++){
    f[i] = f[i-2] + f[i-1];
  }

  cout << f[n] << endl;
  return 0;
}