import java.util.Scanner; public class Main { public static void main(String[] args) { Main main = new Main(); Scanner scan = new Scanner(System.in); int number = scan.nextInt(); System.out.println(main.isPrimeNumber(number)); } public Boolean isPrimeNumber(int number) { //write your code here...... // if(number==2||number==3)return true; // if(number%6!=1&&number%6!=5)return false; // int temp=(int)Math.sqrt(number); // for(int i=5;i<=temp;i+=6){ // if(number%i==0||number%(i+2)==0){ // return false; // } // } // return true; int n = number/2; for(int i =2;i<n;i++){ if(number%i==0){ return false; } } return true; } }