title: storing input into Arrays C++
body: <p>I am learning about arrays , what I wanted to try is first let the user enter x,y values 4 times
  e.g </p>
  
  <p>first time</p>
  
  <pre><code>x = 1
  y = 3
  </code></pre>
  
  <p>second time</p>
  
  <pre><code> x = 2
   y = 3
  </code></pre>
  
  <p>third time</p>
  
  <pre><code> x = 3
   y = 1
  </code></pre>
  
  <p>fourth time</p>
  
  <pre><code> x = 1
   y = 3
  </code></pre>
  
  <p>. and then store the value that the user had key in 4 times inside a array and print them out but I getting some weird outputs.</p>
  
  <p>my output</p>
  
  <pre><code>10001711642800 &lt;-- some weird output
  </code></pre>
  
  <p>expected output</p>
  
  <pre><code>1,3
  2,3
  3,1
  1,3
  </code></pre>
  
  <p>code(not working)</p>
  
  <pre><code>      int x;
        int y;
  
       //request the user to enter x and y value 4 times.
       for (int i=1; i&lt;5; i++) {
          cout &lt;&lt; i &lt;&lt; "Please enter x-cord." &lt;&lt; endl;
          cin &gt;&gt; x;
  
          cout &lt;&lt;i &lt;&lt; "Please enter y-cord." &lt;&lt; endl;
          cin &gt;&gt; y;
      }
       //intitalize the array size and store the x,y values   
      int numbers[4][4] = { 
          x, y
      };
      //loop through 4 times to print the values.
      for (int i = 0; i&lt;5; i++) {
          cout &lt;&lt; numbers[i][i];
      }
  </code></pre>
  
  <p>I know it can be done with vectors but now I am trying with arrays because I am weak in using arrays.</p>