// add new Customer System.out.println("Enter Customer ID"); int tempID= UserInput.readInt(); System.out.println("Enter Customer's Name"); String tempName= UserInput.readString(); UserInput.prompt("Enter Customer's Phone Number"); String tempPhone = UserInput.readString(); Customer tempNew= new Customer(tempID, tempName, tempPhone);
This won't work as it will constantly create the customer object "tempNew". How can I use user input to name it differently each time? Is this even possible, or I am simply going about the whole process incorrectly?
Thank you for your time,