title: Sort files in numeric order
body: <p>I made a program to combine all files in a folder together.</p>
  
  <p>Here's part of my code:</p>
  
  <pre><code>File folder = new File("c:/some directory");
  File[] listOfFiles = folder.listFiles();
  for (File file : listOfFiles){
  
  if (file.isFile()){
      System.out.println(file.getName());
      File f = new File("c:/some directory"+file.getName());
  </code></pre>
  
  <p>However, I hope my files can be in order of like:
  job1.script, job2.script, .....</p>
  
  <p>but I get:
  job1.script, job10.script, job11.script, that 10,11,12... are in front of 2.</p>
  
  <p>I hope I can get efficient code that can avoid this problem.</p>