Function to check if chocolates can be eaten for ' mid ' no . of days
static bool helper ( int mid ) { int cnt = 0 ; foreach ( KeyValuePair < int , int > i in mp ) { int temp = i . Value ; while ( temp >= mid ) { temp -= mid ; cnt ++ ; } }