Chocolate Feast

Solution to Hacker Rank problem Chocolate Feast