请大家指点一下WHILE语句
我在写WHILE语句的时候,好象有些问题,请大家指点
下面我想写的是,如果输入的数字大于3,系统显示GOOD,否则,系统继续要求USER输入一个数字
import javax.swing.*;
public class A{
public static void main(String args[]){
int input2;
boolean Int = false;
while(!false){
String input = JOptionPane.showInputDialog("Enter a integer");
input2 = Integer.parseInt(input);
if(input2 < 3){
Int = false;
}
else{
Int = true;
System.out.println("good"); }
System.exit(0);
}
}
}