Ask Question

How to check if the next number is an int in java

+5
Answers (1)
  1. 15 July, 18:18
    0
    Id you are using java. util. Scanner; to see if the next number is an int do

    input. hasNextInt ();

    Notice that this returns a bolean.
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “How to check if the next number is an int in java ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers