# Problem of the Week Problem C A Solo Trio

Sandip is writing a computer program that will play sounds that imitate a piano, cello, and violin. He has commands that start or stop the sound of each instrument, as well as a command to wait for a given period of time while the instruments play. He uses these commands to write the following program.

REPEAT 10 times:

• start(piano)

• wait(3sec)

• start(cello)

• start(violin)

• wait(5sec)

• stop(violin)

• wait(2sec)

• start(violin)

• stop(piano)

• wait(2sec)

• stop(violin)

• stop(cello)

1. How long does it take for the program to execute completely from start to finish? Assume that Sandip’s computer is so fast that it doesn’t take any time at all to execute each command.

2. Which instruments are playing exactly $$33$$ seconds after the program starts running?

Theme: Computational Thinking