How can I call a method by pressing a JButton?
For example:
when JButton is pressed hillClimb() is called;
I know how to display me
btnMyButton.addActionListener(e->{ JOptionPane.showMessageDialog(null,"Hi Manuel "); });
with lambda