Scanner sc=new Scanner("sue3,true3;").useDelimiter(";");
int h=sc.nextInt();
In above example and does Scanner object always ,throw
an InputMismatchException ,if not able to extract the token out of
string based on regex.
Means if no match ,we will get Exception.