I am fairly new to Java programming and have been using a for loop in my program. I noticed whenever my program asks for user input, that whenever I press the enter key that is used as the next key for the second iteration of the loop. Is there a way to make this not occur?
-
Does this answer your question? How to read input with multiple lines in Javafunky– funky2021-02-19 00:44:56 +00:00Commented Feb 19, 2021 at 0:44
-
2Welcome to StackOverflow. This question really needs a Minimal Reproducible Example to go with it. Cheers. Also do check out the other answer @funky mentions.Adam Burke– Adam Burke2021-02-19 00:45:42 +00:00Commented Feb 19, 2021 at 0:45
Add a comment
|