title: Display Array ColumnWise
body: <p>I need to display an array of numbers. The output needs to be this:</p>
  
  <pre><code>10 25 29 13 46 30 26 57 41 34 88 52 60 77 82
  </code></pre>
  
  <p>I currently have it working but its not displaying column-wise, here is my output: </p>
  
  <pre><code>10 13 26 34 60 25 46 57 88 77 29 30 41 52 82
  </code></pre>
  
  <p>I found a similar question with answer on here but it was for rows that aren't all the same length, so I don't think it will be helpful to use it.</p>
  
  <p>Here is my code (also I'm new to java):</p>
  
  <pre><code>public class test
  {
  public static void main(String[] args)
  {
  
  int rows = 3;
  int cols = 5;
  
  
  int intar [][] = {  {10, 13, 26, 34, 60} ,
                  {25, 46, 57, 88, 77},
                  {29, 30, 41, 52, 82} };
  
  
  
  for (int i = 0; i &lt; rows; i++) {
    for (int j = 0; j &lt; cols; j++) {
      System.out.print ( intar[i][j] + " " );
    }
  }
  
  
  }
  }
  </code></pre>