solving little elephant and candies