#include #include #include using namespace std; class Number { public: Number() {} Number(string n) : num(n) {num = string(num.rbegin(), num.rend());} void show(); void operator=(string n) {*this = Number(n);} friend string operator+(const Number& left, const Number& right); int strLen() {return num.length();} string str() {return num;} private: string num; }; void Number:: show() { for (string::reverse_iterator it = num.rbegin(); it != num.rend(); ++it) { cout << *it; } cout << endl; } string operator+(const Number& left, const Number& right) { string ans, st, lg; if (left.num.length() > right.num.length()) { lg = left.num; st = right.num; } else { st = left.num; lg = right.num; } int add; int fuck = 0; for (size_t i = 0; i < st.length(); ++i) { add = st[i] + lg[i] + fuck - 2 * '0'; fuck = add / 10; add %= 10; ans += (add + '0'); } for (size_t i = st.length(); i < lg.length(); ++i) { add = lg[i] + fuck -'0'; fuck = add / 10; add %= 10; ans += (add + '0'); } if (fuck) ans += '1'; ans = string(ans.rbegin(), ans.rend()); return ans; } Number fuckit[201]; int main() { fuckit[1] = "1"; fuckit[2] = "2"; for (int i = 3; i<= 200; ++i) { fuckit[i] = fuckit[i-2] + fuckit[i-1]; } int n; while (scanf("%d", &n) != EOF) { fuckit[n].show(); } return 0; }