Suppose you are creating a stockbroker application. It performs two commands which are buy and sell. Use the command pattern to implement this application. Use the following guidelines:
- Don't change the provided code.
- The
sellcommand must printStock was sold. - The
buycommand must printStock was bought. - First, it must perform a
buycommand, then thesellcommand.