* This code solves the problem Filling Jars from Hackerrank
 * The problem is at: https://www.hackerrank.com/challenges/filling-jars