title: Add functionality to a menu button in java
body: <p>I am new to Java and I was wondering how to add functionality to menu item?<br>
  What I would like it to do, is to set two values to 0.</p>
  
  <p>This is the code I have currently:</p>
  
  <pre><code>JMenuItem clear = new JMenuItem("Clear");
  Options.add(clear);
  </code></pre>