#include<stdio.h>
int t[50];

int f(int n){
if(n == 0 || n == 1)
return t[n] = 1;
else return f(n - 2)+f(n - 1);
}

int main(){
int n;
scanf("%d",&n);
if(n >= 0)
printf("f(%d) = %d\n",n,f(n));
return 0;
}