title: enters an infinite loop when catching exception
body: <pre><code>int option;
      while(true) {
          try {
              option = sc.nextInt();
          }
          catch(Exception e) {
              System.out.println(e);
              continue;
          }
          if(option != 1 &amp;&amp; option !=2) {
              System.out.println("Please choose one of the above options!");
              continue;
          }
          break;
      }
  </code></pre>
  
  <p>so why if I input a string the code enters an infinite loop ?</p>