/**
 *  This is a simple main/application class to test the user of 
 *  the Scanner class.
 *  It uses an input text file called "testfile".
 *  @author Leen-Kiat Soh
 *  @version 1.0
 *  
 */

import java.util.*;
import java.io.*;

class TestScanner  {

   public static void main( String[] args)  {

      File tfile;
      tfile = new File("testfile");

      try {
         Scanner scanner = new Scanner(tfile);
         String x = scanner.next();
         System.out.println(x);
	 int y = scanner.nextInt();
         System.out.println(y);
	 double z = scanner.nextDouble();
         System.out.println(z);
	 x = scanner.next();
         System.out.println(x);
      }  catch (FileNotFoundException e)  {}



   }

}


