import java.util.Scanner;
public class java{
public static void main(String[]argv){
int x;
Scanner sc=new Scanner(System.in);
x=sc.nextInt();
if (x%5==0) {
System.out.println("U");
}
else if (x%5==1) {
System.out.println("G");
}
else if (x%5==2) {
System.out.println("Y");
}
else if (x%5==3) {
System.out.println("T");
}
else if (x%5==4) {
System.out.println("I");
}
}
}