title: Using an array to store multiple variables from user input
body: <p>I am relatively new to Java and would like to know how to store variables separately from a single line of user input.</p>
  
  <p>At the minute the user is prompted to enter football results in the following format</p>
  
  <pre><code>home_name : away_name : home_score : away_score
  </code></pre>
  
  <p>and I am using a while loop to continue to ask user for input until they enter "stop" </p>
  
  <pre><code>(while (input != "stop))
  </code></pre>
  
  <p>Once the loop is broken I would like my program to output a variety of data such as total games played, but I'm struggling to store the <code>home_name</code>, <code>away_name</code> etc.. especially if the user wishes to enter multiple lines of results.</p>