Ok, I have searched on this site, google, and I have skimmed the documentation for the Scanner... and still cannot figure out what is wrong with this. I have simplified the offending code:
No matter what I do, I cannot read any input with decimals. I can only input integers into this. If I try something like 3.11225 or even 1.1, I get this junk:
Exception in thread "main" java.util.InputMismatchException
I tried it as well, and found out that Scanner is locale sensitive. You probably use , as the decimal separator, just like me. Using 1,1 will work. I added "scan.useLocale(Locale.US);" before the call to nextDouble, and then 1.1 does work.