I'm using Windows. When running a java class file from cmd in windows, pressing ctrl+z enters the symbols ^z, and it's seen as what I think is called an 'End-of-file indicator'. It's useful for a situation like this:
while ( input.hasNext() )
a = input.nextInt();
When this generic while-loop is running, you can obviously enter whatever integer and it gets stored in the varaible 'a', and to exit the loop when running the application in cmd, you do what I said above: ctrl+z, press enter, and it exits the while loop. On mac and linux it would be ctrl+d.
But the same is not true in IntelliJ's run tool (I think that's what it's called). Pressing ctrl+z does nothing, and manually inputting "^z" just creates an error (not an integer obviously).
So, does it have a different end-of-file indicator? How would one exit this while loop from the run tool?