私は Java プログラミングを学んでいますが、このコードに問題があります。私の問題は、2 番目の while ループを停止できないことです ( while (done ==1){ .. }
)
done = 2 を実行すると、プログラムが再開されます...
int stopme3 = 1;
while (stopme3 == 1) {
/* Appel de la méthode Afficher les propriétaires */
AfficherProprio();
int choix_proprio = ChoisirProprio();
/* Appel de la méthode Afficher les Comptes du Propriétaire */
AfficherComptesProprietaire(choix_proprio);
/* Choix du compte à modifier */
System.out.println("N° de compte:");
int choixCompte = lectureClavier.nextInt();
/* Test si comptes existants du proprio */
if (choixCompte == tab_compte[choix_proprio]._num_compte) {
int done = 1;
while (done == 1) {
/* Création d'une ligne comptable */
tab_compte[choix_proprio].CreerLigneC();
System.out.println("Ajouter une ligne comptable supplémentaire ?");
System.out.println("1 - Oui");
System.out.println("2 - Non");
done = lectureClavier.nextInt();
}
} else {
System.out.println("Compte sélectionné inexistant.");
}
}
助けていただければ幸いです。どうもありがとうございました。