我需要问三个级别的工资。1级必须至少65k,2级必须至少60k。1 级也必须至少是 2 级的 110%。2 级也必须至少是 3 级的 120%。我只从 1 级和 2 级开始,因为如果我能弄清楚,我就能弄清楚 3 级.这是我所拥有的:
do {
System.out.println("Please enter the full time employee payscale level 1 rate: ");
fullTimePay1 = input.nextInt();
} while (fullTimePay1 < 65000);
do {
System.out.println("Please enter the full time employee payscale level 2 rate: ");
fullTimePay2 = input.nextInt();
} while (fullTimePay2 < 60000);
do {
System.out.println("Please enter the full time employee payscale level 1 rate: ");
fullTimePay1 = input.nextInt();
System.out.println("Please enter the full time employee payscale level 2 rate: ");
fullTimePay2 = input.nextInt();
} while (fullTimePay1 < (fullTimePay2 * 1.1));
但它只是一遍又一遍地重复(我在这段代码之后有一个永远不会执行的打印语句)。谁能告诉我为什么,也许可以帮助我的代码?