title: Java Scanner Class useDelimiter Method
body: <p>I have to read from a text file containing all the NCAA Division 1 championship games since 1933, </p>
  
  <p>the file is in this format:   1939:Villanova:42:Brown:30
                          <strong><em></strong> 1945:New York University:70:Ohio State:65 *</em>*The fact that some Universities have multiple white spaces is giving me lots of trouble beause we are only to read the school names and discard the year, points and colon. I do not know if I have to use a delimiter that discards what spaces, but buttom line is I am a very lost.</p>
  
  <p>We are to discard the date, points, and ":".  I am slightly fimilar with the useDelimiter method but, I have read that a .split("") might be useful.  I am having a great deal of problems due to my lack of knowledge in patterns.</p>
  
  <p>THIS IS WHAT I HAVE SO FAR:</p>
  
  <pre><code>class NCAATeamTester
  {
  public static void main(String[]args)throws IOException
  {
  NCAATeamList myList = new NCAATeamList();     //ArrayList containing teams
  Scanner in = new Scanner(new File("ncaa2012.data"));   
  in.useDelimiter("[A-Za-z]+");      //String Delimeter excluding non alphabetic chars or ints
  while(in.hasNextLine()){
  String line = in.nextLine();
  String name = in.next(line); 
  String losingTeam = in.next(line);
  //Creating team object with winning team 
  NCAATeamStats win = new NCAATeamStats(name); 
  myList.addToList(win);       //Adds to List
  //Creating team object with losing team 
  NCAATeamStats lose = new NCAATeamStats(losingTeam);
  myList.addToList(lose)
  }
  }
  }
  </code></pre>