Ok, so I've recently been working with a lot of probability, and more or less dice problems.

For instance I've developed this:

Say you have a 6 sided die, what is the chance in 3 throws that you get at least one 4 for any throw.

I developed a formula for this.
n^r - (n-1)^r
----------------
n^r

N = number of sides.
R = number of rolls.

So
6^3 - 5^3
------------
6^3

Which is 91/216
I assume this is correct, being if I do 6 sided 2 rolls I get 11/36 and if I do 6 sided 1 roll I get 1/6

So that is for, if I have an N sided die and I roll R times the probability I roll a 4 at least once.

I got past this part, but I'm not very good with anything probability like, being I was never formally educated in it (No Probability and Statistics class under my belt)

Then I wanted to derive a formula for if I had N-Sided dice and I rolled R times, what would be the chances I roll a 4 at least twice.

Being its not possible on the first roll,

For the second roll, I came up with a probability via tables by hand that it is 1/36

being
X-1-2-3-4-5-6
1
2
3
4
5
6

Lines up a 4 and a 4 once in a grid of 36

Then, for 3 rolls I came up with 16/216

being
X-41-42-43-44-45-46-14-24-34-54-64
1
2
3
4
5
6

Lines up a 4 and 4 in 16 areas.

The next one with 4 rolls is 171/1296 I believe.

I was wondering if anyone here nows how I could come up with a formula for this one, I know its atleast
equ
----
n^r
But I can not see the equation in this one.

I sat down and worked some more, and I arrived with this formula, which works with all of the ones I've done by hand.

n^r-(n+r-1)(n-1)^r-1
--------------------------
n^r