#include using namespace std; #define int long long typedef pair P; int INF = 3e18+7; int mod = 1e9+7; int dx[] = {1, 0,-1, 0, 1, 1,-1,-1}; int dy[] = {0, 1, 0,-1, 1,-1, 1,-1}; signed main() { int N; cin >> N; if(N == 2) { cout << "INF" << endl; } else if(N <= 4) { cout << 6 << endl; } else if(N <= 6) { cout << 4 << endl; } else { cout << 2 << endl; } }