An example of using a state machine to implement the logic behind an ATM
To compile the code open the .pro file using the Qt IDE.
Alternatively, compile main.cpp using your favorite C++14 or newer compiler like this:
g++ main.cpp -o main -std=c++14