HackerEarth Balanced Partition problem solution - TheCScience