import java.util.Scanner; public class ASD{ public static void main(String[]args){ Scanner input=new Scanner(System.in); while (input.hasNext()){ int a=input.nextInt(); int count=0; int b=2; while (b<a){ if (a%b==0){ count=1; break; } b++; } if (count==1){ System.out.println("非質數"); }else{ System.out.println("質數"); } } } }