Divide the number of desired outcomes by the total number of possible outcomes.
Here are some examples using an unbiased 6-number die with numbers 1 through 6 on its faces.
Example 1:
What is the probability of rolling a 5?
Number of ways of getting the desired outcome? 1, by rolling a 5.
Total number of possible outcomes: 6, any roll from 1 to 6.
Probability of rolling a 5:
p(5) = (number of desired outcomes)/(total number of outcomes)
p(5) = 1/6
Example 2:
What is the probability of rolling a number grater than 4?
The desired outcome is 5 or 6. The number of ways of getting the desired outcome is 2 since only a 5 or a 6 will work.
Total number of possible outcomes: 6
p(greater than 4) = 2/6 = 1/3