I am trying to use the montecarlo simulation to estimate the probability that all six faces appear exactly once in six tosses of fair die.
> nrep = 100000
> count = 0
for (i in 1:nrep) {
x = sample(1:6, replace = TRUE)
if () count = count + 1
}
What do I ask in the if statement?
I know how to ask the question for a one time roll but not a 6x roll.