Moved example from a separate folder to just example.cpp. Fixed some warnings.