Nested cubes  task c++