C++ implementation on CodeBlocks