I'm creating a java application that at some point during execution needs to display several outputs on a single line by refreshing. It will need to show each output the wait for the user to confirm. I'm stuck on how to pause the output until enter is pressed. By using the following methond:
System.out.print("Test 1\r");
System.in.read();
System.out.print("Test 2\r");
however when I use this method the cursor jumps down to a new line, like so
Test 1
Test 2
Does anyone know an easy work around for this?