C++, code for fun