Hello,
You can Force Quit an application. Press the keys (at the same time) : command + option + escape
You will see a window when you can select an application and click Force Quit.
If that doesn't work, to shut down, press for at least 5 seconds on the power button of your Mac.
Hope this will help.