+ 1
Can someone explain this to me please (Java)
I’ve just started out yesterday (I’m currently on the arrays course on Java) and I’m confused on how to get user input. There’s only been one lesson on it and the lesson didn’t really teach you how to do it, it just showed you how to import the scanner. Can someone please explain how to get user input in Java please? Like how do you get a string input? (The lesson only showed int) Thank you - a neek
6 Respostas
+ 1
complete documentation
https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/util/Scanner.html
0
So is it the double.parsedouble thing?
0
Jayden
No it's not a double.parseDouble things, Scanner class has nextDouble() method. Using scanner class object you can get double value input from the user.