1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34
|
public class course2 {
public static void main (String[]args){
int nbParticipants, option;
System.out.println (" Entrez un nombre de participants ");
nbParticipants = Terminal.lireInt ();
int[] participants = new int[nbParticipants];
for(int i=0; i<nbParticipants; i++ ) {
System.out.println (" ajouter un participant ");
participants[i]=Terminal.lireChar();
}
System.out.println ( " choisir une option ");
System.out.println ( " 1. afficher la liste des participants ");
System.out.println ( " 2. afficher le classement provisoire " );
System.out.println ( " 3. enregistrer une arrivée " );
System.out.println ( " 4. enregistrer un abandon ");
System.out.println (" 5. enregistrer une disqualification ");
System.out.println ( " 6. Quitter ");
option =Terminal.lireInt ();
if ( option == 1) { System.out.println (participants);
}
else { System.out.println (" work ");
}
}
} |