public static void main(String[] args) { String prenom; Scanner sc= new Scanner(System.in); char reponse=' '; int note; do{ System.out.println("Veuillez rentrer votre prenom:"); prenom=sc.next(); System.out.println("Bonjour," +prenom+ "! Rentre ta moyenne:"); note= sc.nextInt(); switch (note){ case (0): System.out.println( "insuffisant"); break; case (10): System.out.println("juste juste"); break; case (20): System.out.print("genial !"); break; } if (note>0 && note<10){ System.out.println("Travail encore plus!"); } else if (note>10 && note<20){ System.out.println("tu atteint presque la perfection!"); } do{ System.out.println("Veux tu recommencer? (O/N)"); reponse= sc.next().charAt(0); }while(reponse !='O' && reponse != 'N'); }while (reponse=='O'); }