How to combine program?? can someone help me with it

Combining is essentially just interleaving the two, but the first thing you need is both codes to be kosher.
The simon one baulks at the second line Tone speakerpin and won't compile.