title: I am only able to print up to "red: 1" only, after which my program ends due to usage of break statement
body: <p>Please see this code:</p>
  
  <pre><code>import java.util.Scanner;
  
  public class Array
  {
      public static void main(String args[])
      {
          String[] names=new String[5];
          Scanner scan=new Scanner(System.in);
          System.out.println("Enter 5 colour:");
          for(int i=0; i&lt;names.length;i++)
          {
              names[i]=scan.nextLine();
          }
          String[] numbers=new String[5];
          Scanner scan2=new Scanner(System.in);
          System.out.println("Enter 5 numbers:");
          for(int j=0; j&lt;numbers.length;j++)
          {
              numbers[j]=scan.nextLine();
          }
          OUTER:
          for (int k = 0; k &lt; names.length; k++)
          {
              System.out.println(names[ k ] + ":");
              break OUTER;
          }
          INNER:
          for (int l = 0; l &lt; numbers.length; l++)
          {
              System.out.println(numbers[ l ]);
              break INNER;
          }
      }
  }
  </code></pre>
  
  <p>I am a newbie, learning Array as of now, in Java. I want to print the outcome of the code above as follows:</p>
  
  <pre class="lang-none prettyprint-override"><code>Enter 5 numbers:
  //Say:
  RED
  GREEN
  BLUE
  PINK
  YELLOW
  Enter 5 numbers:
  1
  2
  3
  4
  5
  
  //Output of the code should be:
  RED: 1
  GREEN: 2
  BLUE: 3
  PINK: 4
  YELLOW: 5
  </code></pre>
  
  <p>How can I print the array? I am only able to print up to "RED: 1" only, after which my program ends due to <code>break</code> statement.</p>