C++ template for competitive programming purposes for VS2012