We created a new private slot in the MainWindow class and connected the clicked() signal of the Start new game button to the slot. When the user clicks on the button, Qt will call our slot, and the code we wrote inside it gets executed.
qDebug() << ... is a convenient way to print debug information to the stderr (standard error output) of the application process. It's quite similar to the std::cerr << ... method available in the standard library, but it separates supplied ...