title: Python script command line input
body: <p>To start i have little knowledge of python as i'm doing this assignment as a school project. I need to achieve the folowing:</p>
  
  <p>create a script which i can start from <code>Windows</code> CMD and i need to add a parameter list to the first 3 files in a directory.</p>
  
  <p>i start the script as follows:</p>
  
  <pre><code>c:\Python34\python.exe c:\Python34\directory.py c:\temp 3
  </code></pre>
  
  <p>content of the script:</p>
  
  <pre><code>##directory.py###
  import os
  import sys
  
  dirs = os.listdir(sys.argv[1])
  print (dirs)
  </code></pre>
  
  <p>The problem is i dont think the command line switch "3" is input in the script. </p>
  
  <p>Any idea how i can achive this?</p>