import java.util.; import java.io.; public class Main{ public static void main(String[] args)throws IOException{ BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); String str = null; while((str = in.readLine())!= null){ int n = Integer.parseInt(str); if(n == 1){ System.out.println(1); continue; } if(n == 2){ System.out.println(2); continue; } int pre = 1; int post = 2; int dest = 0; int i = 3; while(i <= n){ dest = pre + post; pre = post; post = dest; i ++; } System.out.println(dest); } } // public static int clip(int n){ // if(n == 1) return 1; // if(n == 2) return 2; // return clip(n - 1)+clip(n-2); // } }