CodePudding user response:
A simple text scanner, you can use a regular expression parsing the raw type and string,A Scanner mode will enter break to token delimiter, by default matching space, then the can use various next method will be token into different types of values ,
For example, the code allows users from the System. In reading a number:
Scanner sc=new Scanner(System.in);
Int I=sc. NextInt ();