title: Adding multiple jars to classpath on commandline
body: <p>I'm running Ubuntu and want to execute a Java file from terminal by including multiple jar files. </p>
  
  <p>All my jars are included in tha jar folder.</p>
  
  <p>I tried</p>
  
  <pre><code>javac -cp jar/A.jar: jar/B.jar: jar/C.jar: jar/D.jar MyFile.java
  </code></pre>
  
  <p>I get below error.</p>
  
  <pre><code>javac: invalid flag: jar/B.jar:
  Usage: javac &lt;options&gt; &lt;source files&gt;
  use -help for a list of possible option
  </code></pre>
  
  <p>Can anyone guide how to use multiple jars in classpath ?</p>