OpenGenus / cosmos

World's largest Contributor driven code dataset | Used in Quark Search Engine, @OpenGenus IQ, OpenGenus Visual Project
http://internship.opengenus.org
GNU General Public License v3.0
13.56k stars 3.68k forks source link

CODECHEF Marbles (MARBLES) in C and Python #4683

Open ka1shi opened 4 years ago

ka1shi commented 4 years ago

This is a(n):

Details: Rohit dreams he is in a shop with an infinite amount of marbles. He is allowed to select n marbles. There are marbles of k different colors. From each color there are also infinitely many marbles. Rohit wants to have at least one marble of each color, but still there are a lot of possibilities for his selection. In his effort to make a decision he wakes up. Now he asks you how many possibilities for his selection he would have had. Assume that marbles of equal color can't be distinguished, and the order of the marbles is irrelevant.

ka1shi commented 4 years ago

Kindly assign it to me.

wokira commented 4 years ago

I can solve this problem in Java. Kindly allow and assign me this @arnavb