How can I read a double variable from keyboard in Java? I\'m trying to solve this, but it didn\'t works. It said:
Exception in thread \"main\" java.util.I
Tried to reproduce, had no luck. I think that the problem is with your input. here is what I have tried:
input:
s 4.51 2
output:
String: s Double: 4.51 Int: 2
In your code your first scaner takes string, second: double and third takes int.
string
double
int