• + 2 comments

    Very simple. 100% all test cases passed

       static int chocolateFeast(int n, int c, int m) {
            int wrapper=0;
            wrapper=n/c; 
            int choc_count=wrapper;
    				while(wrapper>=m)
            {  
                wrapper=wrapper-m;//exchange
                wrapper++;//new choc wrapper..  so ++
                choc_count++;//increase choc count
            }
            return choc_count;
        }