import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int N = sc.nextInt(); boolean [] b = new boolean [N+1]; ArrayList prime = new ArrayList(); for(int i=2; i<=N; i++){ if(b[i]==false){ prime.add(i); for(int j=2; j<=N; j++){ if(j%i==0){ b[j]=true; } } } } boolean [] WL = new boolean [N+1]; WL[0]=WL[1]=true; for(int i=4; i<=N; i++){ for(int j=prime.size()-1; j>=0; j--){ if(prime.get(j)