public static void main(String[] args) {
// TODO Auto-generated method stub
//Scanner for AccountNumbers
Scanner AccountIn = new Scanner(System.in);
ArrayList<String> AccountNumber = new ArrayList<String>();
System.out.println("Create Account Number");
while(AccountIn.hasNextLine()>0 &&AccountIn.hasNextLine() < 9){
//EveryTime AccountNumber Is created store in Array
AccountNumber.add(AccountIn.nextLine());
money = reader.readDouble("Enter Starting Amount Of Money");
}
}
I am trying to get user Input of the Scanner 'AccountIn' to be greater than 0 and less than 9 how can I do this? Should I create a variable of the input and then list in the while loop? or should I use the try and catch exception?
AccountIn?