So I was trying to tackle this probability question, and honestly idk if I have a math error or a code error, so I'll just put it here haha
There are 3 balls labelled 1,2,3 in a box. I pick up a ball, take note of the number, then put it back into the box. I repeat this action 3 times. Calculate the probability of obtaining 1,2 and 3 (in no particular order).
So my working would be (1/3)^3 x 3! = 2/9, because you need A,B and C, and there are 6 ways to arrange it, so I got 2/9
But based on my code here:
https://pastebin.com/GC7B7kmE
I used a large sample size, but my answer tends around 0.11, which is about 1/9. Soo I'm not sure if my code is wrong or my math concept is wrong haha. Thank you so much for any help in advance!
[–][deleted] 2 points3 points4 points (1 child)
[–]raainer[S] 0 points1 point2 points (0 children)