title: Paste side by side multiple files by numerical order
body: <p>I have many files in a directory with similar file names like file1, file2, file3, file4, file5, ..... , file1000. They are of the same dimension, and each one of them has 5 columns and 2000 lines. I want to paste them all together side by side in a numerical order into one large file, so the final large file should have 5000 columns and 2000 lines. </p>
  
  <p>I tried </p>
  
  <pre><code>for x in $(seq 1 1000); do 
  paste `echo -n "file$x "` &gt; largefile
  done
  </code></pre>
  
  <p>Instead of writing all file names in the command line, is there a way I can paste those files in a numerical order (file1, file2, file3, file4, file5, ..., file10, file11, ..., file1000)?</p>
  
  <p>for example:</p>
  
  <p>file1</p>
  
  <pre><code>1 1 1 1 1
  1 1 1 1 1 
  1 1 1 1 1
  ...
  </code></pre>
  
  <p>file2</p>
  
  <pre><code>2 2 2 2 2 
  2 2 2 2 2
  2 2 2 2 2 
  ....
  </code></pre>
  
  <p>file 3</p>
  
  <pre><code>3 3 3 3 3 
  3 3 3 3 3 
  3 3 3 3 3
  ....
  </code></pre>
  
  <p>paste file1 file2 file3 .... file 1000 > largefile</p>
  
  <p>largefile</p>
  
  <pre><code>1 1 1 1 1 2 2 2 2 2 3 3 3 3 3
  1 1 1 1 1 2 2 2 2 2 3 3 3 3 3
  1 1 1 1 1 2 2 2 2 2 3 3 3 3 3
  ....
  </code></pre>
  
  <p>Thanks.</p>