title: How to make a Java program that will open the calculator app "X" number of times
body: <p>I am trying to make a simple program that when I run it, it opens the Calculator app on my computer X number of times. This is what I tried to do, and it would only open it once.</p>
  
  <pre><code>import java.util.*;
  import java.io.*;
  public class main {
  
  public static void main(String[] args) throws IOException {
  
      Runtime run = Runtime.getRuntime();
  
      for (int i = 0; i &lt; 5; i++)
      {
              run.exec("calc");
      }
    }
  }
  </code></pre>