Number of rolls to get my desired result with a set probability I want to know the number of rolls or throws of a die or a coin with an equal distribution to get to my desired result with a given probability.
In my specific case I want to roll at least one "1" and one "2" on an eight sided die. Before I get one of the numbers, I would have a probability of 2/8 to get one of my numbers, either "1" or "2". after I got one of these I would have a 1/8 chance to get my missing number. How often do I have to throw the dice to get both numbers with a probability of 90%?
Edit: I am throwing 1 die, and I want to know the number of throws needed to get "1" and "2" at least once with a chance of 90%. 
 A: I believe this will require 23 rolls with an 8 sided die.
the probability that you get both numbers is 1 - the probability that you either get 1 of the 2 or neither of the two
P[both]=1-P[first only]-P[second only]-P[neither]
The probability of getting just one of them is the sum of the probabilities of all the possible numbers of times that you got that one roll.  So if you roll 4 times, you get the one number 1, 2, 3, or 4 times.  The probability of getting that is (1/8)^(that number) times the probability that you don't get the other (6/8)^(all other rolls, i.e. total rolls minus number of times you got the first) times the number of combinations that make that possible rolls choose number of times you get the number.  For n rolls sum over a number k of times you got the first number of interest: $\sum_{k=1}^{4}(\frac{6}{8})^{4-k}(\frac{1}{8})^k{4\choose k}$
The probability of getting neither number for n rolls is just the probability of getting neither on a single roll (6/8) raised to power of the number of rolls (6/8)^n
$P[both]=1-\sum_{k=1}^{n}(\frac{6}{8})^{n-k}(\frac{1}{8})^k{n\choose k}-\sum_{k=1}^{n}(\frac{6}{8})^{n-k}(\frac{1}{8})^k{n\choose k}-(\frac{6}{8})^n$
$P[both]=1-2\sum_{k=1}^{n}(\frac{6}{8})^{n-k}(\frac{1}{8})^k{n\choose k}-(\frac{6}{8})^n$
Using Matlab with n=23, I get p = 0.9086
