#include using namespace std; typedef long long ll; typedef pair P; int main(){ ll n; cin >> n; if(n==2){ cout << "INF" << endl; } else if(n==3){ cout << 6 << endl; } else if(n==4){ cout << 6 << endl; } else if(n==5){ cout << 4 << endl; } else if(n==6){ cout << 4 << endl; } else{ cout << 2 << endl; } }