const rl = require("readline").createInterface({ input: process.stdin });
var iter = rl[Symbol.asyncIterator]();
const readline = async () => (await iter.next()).value;

void (async function () {
    // Write your code here
    let line =  Number(await readline());
    let dep = [];
    let func = function func(num) {
        if (num === 1) {
            dep[num] = 1;
            return 1;
        }
        if (num === 2) {
            dep[num] = 2;
            return 2;
        }
        if(!dep[num]){
            dep[num] = func(num-2)+func(num-1)
        }
        return dep[num]
    };
    func(line)
    console.log(dep[line])
})();