Ivan's submission of Choosing from Buckets | CodeChef