HackerEarth Equal Division problem solution - TheCScience