examples: added q1.cpp and tentative q2.cpp