Go: package main

import (
	"bufio"
	"io"
	"os"
	"strconv"
	"fmt"
)

var (
	nstr   func() string
	stdout *bufio.Writer
)

func init() {
	nstr = newReadString(os.Stdin)
	stdout = bufio.NewWriter(os.Stdout)
}

func main() {
	defer stdout.Flush()
	n := nint()
	r := fibonacci(n)
	fmt.Println(r)
}

func fibonacci(n int) int{
	if n == 0 || n == 1{
		return 1
	}else{
		fiList := make([]int, n+1)
		fiList[0] = 1
		fiList[1] = 1
		for i:=2; i<n+1; i++{
			fiList[i] = fiList[i-1] + fiList[i-2]
		}
		return fiList[n]

	}

}

func newReadString(ior io.Reader) func() string {
	r := bufio.NewScanner(ior)
	r.Buffer(make([]byte, 1024), int(1e+11))
	r.Split(bufio.ScanWords)

	return func() string {
		if !r.Scan() {
			panic("Scan failed")
		}
		return r.Text()
	}
}

func nint64() int64 {
	i, err := strconv.ParseInt(nstr(), 0, 64)
	if err != nil {
		panic(err.Error())
	}
	return i
}

func nint() int {
	return int(nint64())
}

func getIntSlice(n int) []int {
	b := make([]int, n)
	for i := 0; i < n; i++ {
		b[i] = nint()
	}
	return b
}

func getStringSlice(n int) []string {
	b := make([]string, n)
	for i := 0; i < n; i++ {
		b[i] = nstr()
	}
	return b
}

func gcd(x, y int) int {
	if y == 0 {
		return x
	}
	return gcd(y, x%y)
}

func lcm(x, y int) int {
	return x * y / gcd(x, y)
}

func contains(s []int, e int) bool {
	for _, a := range s {
		if a == e {
			return true
		}
	}
	return false
}

func bin(i int, prefix bool) string {
	i64 := int64(i)

	if prefix {
		return "0b" + strconv.FormatInt(i64, 2)
	} else {
		return strconv.FormatInt(i64, 2)
	}
}

func strReverse(s string) string {
	runes := []rune(s)
	for i, j := 0, len(runes)-1; i < j; i, j = i+1, j-1 {
		runes[i], runes[j] = runes[j], runes[i]
	}

	return string(runes)
}

C++: #include <iostream>
using namespace std;

int main(int argc, char const *argv[])
{
    int a, *Fibonacci;
    cin >> a;
    Fibonacci = (int *)malloc((a+1) * sizeof(int));
    Fibonacci[0] = Fibonacci[1] = 1;
    for(int i=2; i<=a; ++i) {
        Fibonacci[i] = Fibonacci[i-1] + Fibonacci[i-2];
    }
    cout << Fibonacci[a] << endl;
    return 0;
}

C++: #include <bits/stdc++.h>

using namespace std;

int fibo(int n){
    if(n < 2) return 1;
    return fibo(n-1)+fibo(n-2);
}

int main(){
    int n; cin >> n;
    cout << fibo(n) << endl;
}

C++: #include <iostream>
using namespace std;

int main()
{
  int n;
  cin >> n;
  int F[50];
  F[0] = F[1] = 1;
  for (int i = 2; i <= n; i++) F[i] = F[i - 1] + F[i - 2];
  cout << F[n] << endl;
  return 0;
}

C++: #include <iostream>
using namespace std;
int main(){
	int n; cin>>n;
	int r[] = {1,1,2};
	if( n<=2 ){
		cout<<r[n]<<endl;
		return 0;
	}
	while( n>0 ){
		int tmp = r[1] + r[2];
		r[0] = r[1]; r[1] = r[2]; r[2] = tmp;
		n = n-1;
	}
	cout<<r[0]<<endl;
	return 0;
}

C++: #include <iostream>
#include <stdio.h>
#define MAX 50
using namespace std;

int main(int argc, char *argv[])
{
    int n;
    int fib[MAX] = {0};
    fib[0] = 1;
    fib[1] = 1;
    scanf("%d", &n);
    if (n < 2)
    {
        printf("%d\n", 1);
        return 0;
    }

    for (int i = 2; i <= n; i++)
    {
        fib[i] = fib[i - 1] + fib[i - 2];
    }
    printf("%d\n", fib[n]);
    return 0;
}

C++: #include <bits/stdc++.h>

#define REP(i ,n) for(int i=0 ;i < n; i++)
#define REPB(i ,n) for(int i=n; i >= 0; i--)
#define FOR(i ,m ,n) for(int i=m; i < n; i++)
#define FORB(i, m, n) for(int i=m; i>= m; i--)
#define ll long long
#define pb push_back
#define popb pop_back
using namespace std;
vector<int> f;
int makeFib(int k){
    f.pb(1);
    f.pb(1);
    if(k >= 2){
    FOR(i,2,(k + 1)){
        f.pb(f[i - 2] + f[i - 1]);
      }
    }
      return f[k];
  }
int main(){
  int n;
  cin >> n;

  cout << makeFib(n) << endl;
}

C++: #include <iostream>
using namespace std;

int dp[50];

int main() {
  int n;
  cin >> n;
  dp[0] = 1;
  dp[1] = 1;
  for (int i = 0; i <= 44; i++) {
    dp[i + 2] = dp[i + 1] + dp[i];
  }
  cout << dp[n] << endl;
  return 0;
}

C++: #include <iostream>
using namespace std;

signed main() {
  int n; cin >> n;
  int f[50];
  f[0] = f[1] = 1;

  // メモ化再帰
  for(int i = 2; i <= n; i++) {
    f[i] = f[i-1]+f[i-2];
  }
  cout << f[n] << endl;
  return 0;
}

C++: #include<bits/stdc++.h>
using namespace std;

int main() {
  vector<int> fib(100, 0);
  fib[0]=fib[1]=1;
  for (int i=2; i<100; i++) fib[i]=fib[i-1]+fib[i-2];
  int n; cin>>n;
  cout<<fib[n]<<endl;
}

C++: /*
http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=ALDS1_10_A&lang=jp
*/
#include<iostream>
using namespace std;
typedef long long ll;
#define rep(s,e) for(int i=s;i<e;i++)
ll A[44];
ll Fibo(int n){
  if(n==0 || n==1) return 1;
  if(A[n]!=0) return A[n];
  A[n-1]=Fibo(n-1);
  return A[n-1]+A[n-2];
}
int main(){
  int n;
  cin>>n;
  A[0]=A[1]=1;
  cout<<Fibo(n)<<"\n";
}

C++: #include <iostream>

using namespace std;

int main() {
    int n;
    cin >> n;
    int fib[50];
    fib[0] = 1;
    fib[1] = 1;
    for(int i = 2;i < 50; i++)
    {
        fib[i] = fib[i-1] + fib[i-2];
    }
    cout << fib[n] << endl;
    return 0;
}

C++: #include<stdio.h>
#include<iostream>
using namespace std;

int fibo(int x) {
  int a;
  if ( x == 0 ) return 1;
  if ( x == 1 ) return 1;
  a = fibo(x-1) + fibo(x-2);
  return a;
}

int main() {
  int x, y;
  int F[50];
  F[0] = F[1] = 1;
  for ( i = 2; i < 50; i++ ) F[i] = F[i-1] + F[i-2];

  cin >> x;
  cout << F[x] << endl;

  return 0;
}

C++: #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int, int> pii;


int main()
{	
	ll n,t[50]={};
	cin>>n;
	t[0]=1;
	t[1]=1;
	for(int i=2;i<=44;i++)t[i]=t[i-1]+t[i-2];
	cout<<t[n]<<endl;
	return 0;	
}

C++: #include <iostream>
  
using namespace std;
  
typedef unsigned long long ull;
  
int main()
{
    ull t[45] = { 1, 1 };
    for( int i=2; i<45; ++i )
        t[i] = t[i-1] + t[i-2];
    ull n;
    cin >> n;
    cout << t[n] << endl;
}

C++: #include <bits/stdc++.h>
using namespace std;


int fib(int n){
	  if(n==0 or n==1) return 1;
	  return fib(n-1) + fib(n-2);
}

int main (){

	  int n;
	  cin >> n;
	  cout << fib(n) << endl;

}

C++: #include <iostream>

using namespace std;

int main()
{
	int a=1,b=1,n;
	cin>>n;
	for (int i=0; i<n-1; i++) {
		swap(a,b);
		a+=b;
	}
	cout<<a<<endl;
}

C++: #include <iostream>

const int MAX_SIZE = 44 + 1;

int main() {
  int f[MAX_SIZE] = {0};
  
  int n = 0;

  std::cin >> n;

  f[0] = 1;
  f[1] = 1;

  for (int i = 2; i <= n; i++) {
    f[i] = f[i - 1] + f[i -2];
  }

  std::cout << f[n] << std::endl;

  
  return 0;
}

C++: #include <iostream>

using namespace std;

int N;
unsigned long memo[50] = {};

unsigned long fibo(unsigned n)
{
	if (n <= 1) return 1;
	if (memo[n] == 0) {
		memo[n] = fibo(n - 1) + fibo(n - 2);
	}
	return memo[n];
}

int main()
{
	cin >> N;

	cout << fibo(N) << endl;

	return 0;
}

C++: #include<bits/stdc++.h>
using namespace std;

int f[50];

int fib(int n) {
	if (n == 0)return 1;
	if (n == 1)return 1;
	if (f[n] != 0)return f[n];
	f[n] = fib(n - 1) + fib(n - 2);
	return f[n];
}

int main() {
	ios::sync_with_stdio(false);
	cin.tie(0);

	fill(f, f + 50, 0);

	int N; cin >> N;
	cout << fib(N) << endl;
}

C++: #include <iostream>
using namespace std;
#include <cstdio>
#include <cmath>
#include <cstring>
#include <string>
#include <algorithm>
#include <functional> //sort(A,A.end(),greater<int>());???????????????
#include <queue>
#include <stack>
#include <vector>

#define INF 10 << 10

int main() {
	int n;
	int dp[64];
	dp[0] = 1; dp[1] = 1;

	cin >> n;
	for (int i = 2; i <= n; ++i) {
		dp[i] = dp[i - 1] + dp[i - 2];
	}
	cout << dp[n] << endl;

	return 0;
}