//https://ncode.syosetu.com/n4830bu/303/ #include using namespace std; #include using boost::multiprecision::cpp_int; cpp_int maine(int L) { if (L == 0) return 0; cpp_int maine = 1, book = 1; for (int _ = 0; _ < L - 2; _++) { book += maine; swap(book, maine); } return maine; } int main() { int L; cin >> L; if (L == 2) cout << "INF" << endl << 0 << endl; else cout << L << endl << maine(L) - !(L & 1) * maine(L / 2) * maine(L / 2) << endl; }