HackerRank Shape and Reshape in python problem solution - TheCScience