Processing and Arduino, Sound playing need button to stop it

We are fairly new to Arduino and processing.
So we are doing a project where we are making and arduino alarm clock. We decided to incorporate it into Processing and it has worked well.
We are now at the point where we want our alarm sound to turn off using a button that is connected on the arduino. Any advice on how to achieve this ?

Any advice on how to achieve this ?

Add a button to one of the inputs between the input pin and ground and enable the internal pull ups. When the alarm is sounding then read the button in a loop and if it is pressed stop the sound and exit the loop

Without any real details about exactly what you are doing that is as close as anyone can get to a solution for you without guessing a hell of a lot about what you actually have.