Take a look at this for more information on using the Scanner class.
Scanner (Java 2 Platform SE 5.0)

Also wrap your code in this format to preserve formatting.


<code>