I need a way to control that my program finds the right amount of different results you can get on nd6. Let's say that i have 2d6, then the total amount of results would be $6^2 = 36$. But the different amount of results would be 21, i know this since i counted. The thing is that i do not want to count for 10d6.
Asked
Active
Viewed 218 times
1
-
So you want to regard the dice as indistinguishable? A throw of 5-3 is the same regardless of which die had the 5 and which the 3? – Joffan Dec 11 '16 at 22:02
-
Yes, order doesnt matter – Zaizer zazza Dec 11 '16 at 22:04
1 Answers
1
This can be translated into a stars and bars problem, where you are putting some number of balls (throws) into one of six boxes (results). For the 2d6 case that you worked out, the answer is as you found, $\binom{2+6-1}{2}= 21$. So the number of different outcomes for 10d6 is just $\binom{10+6-1}{10} = 3003$
Joffan
- 39,627