i need help with one exercise in java, i\'m stuck on this error 2 hours maybe. Any help would be great.
Exception in thread \"main\" java.util.InputMismatch
This Exception Thrown by a Scanner to indicate that the token retrieved does not match the pattern for the expected type, or that the token is out of range for the expected type.
String imer = input.next();// Use for String Input
input.nextLine();//Use for next line of input
int cenar = input.nextInt();
You need to put an int in before you get to imer or cenar:
n=input.nextInt();
This line doesn't appear to be doing anything, either remove it, or put a number in before you put your imer or cenar values in.