some C++ exercises