Campbell Ritchie wrote:Has nobody noticed that line 48 is in a loop all by itself? All that does is keep reading ints from System.in.
If you are trying to avoid a non‑int, that is the wrong way to do it. You wantActually you want a utility class for your keyboard input:-I am afraid you have some very bad design. Parallel arrays are a very bad and non‑object‑oriented design, and very error‑prone because it is easy to get the numbers out of phase. Create a Product class encapsulating price and description. Don't write all the names twice. Iterate the array and print the elements from the array.
Daniel Demesmaecker wrote:simply input dosn't have a value yet when it get's to the loop, use a do while instead...
and it's also unclear to me what you're trying to do, my guess is to make this work you'll need to move your menu and the adding of the price inside your loop....
I also wouldn't use 2 array's to keep track of the product and it's price but create an object for it
've tried tons of methods to resize things, set padding, preferd col/rows, alignments but like 90% of them do not work. What Ive managed to read online ab fx is that it somehow doesnt care because of a parent node?