Math Core

Lesson 10.4 · Data and Probability

Counting outcomes

To find a probability, you need to know how many outcomes there are. Listing them works when there are only a few, but a 44-digit phone passcode has thousands of possibilities. In this lesson you'll learn to count outcomes without listing every one, using tree diagrams and a single multiplication rule.

Tree diagrams

A tree diagram shows every outcome of a process that happens in stages. Each stage branches into all of its possible choices, and each complete path is one outcome.

Worked example: Building a sandwich

A deli offers 33 breads (white, wheat, rye) and 44 fillings (turkey, ham, tuna, veggie). How many different sandwiches with one bread and one filling are possible?

Branch on the bread first, then on the filling.

  • White: turkey, ham, tuna, veggie
  • Wheat: turkey, ham, tuna, veggie
  • Rye: turkey, ham, tuna, veggie

Each of the 33 breads has 44 branches, so there are 3×4=123 \times 4 = 12 sandwiches.

The tree shows why multiplying works: every choice at the first stage gets the same number of branches at the next stage.

The Fundamental Counting Principle

Fundamental Counting Principle

If one choice can be made in mm ways and a second choice can then be made in nn ways, the two choices together can be made in m×nm \times n ways. For more stages, keep multiplying: m×n×p×…m \times n \times p \times \dots

This saves a lot of drawing. A lunch special with 33 breads, 44 fillings and 55 drinks has 3×4×5=603 \times 4 \times 5 = 60 possible meals, and you don't need to draw 6060 branches.

Worked example: Locker codes

A locker code uses 33 digits, each from 00 to 99.

  1. How many codes are possible if digits can repeat?
  2. How many codes are possible if no digit can be used twice?

Solutions.

  1. Each of the three positions has 1010 choices: 10×10×10=1,00010 \times 10 \times 10 = 1{,}000 codes.
  2. The first digit has 1010 choices. Once it's used, the second has only 99, and the third has 88: 10×9×8=72010 \times 9 \times 8 = 720 codes.

Common mistake

Read carefully to see whether choices can repeat. If they can, every stage has the same number of choices. If they can't, the number of choices drops by one at each stage.

Arrangements

An arrangement puts items in order. Because each item can be used only once, the choices shrink at each step.

Worked example: Books on a shelf and a race

  1. In how many ways can you arrange 55 different books on a shelf?
  2. Eight runners are in a race. In how many ways can first, second and third place be awarded?

Solutions.

  1. There are 55 choices for the first spot, then 44, then 33, then 22, then 11: 5×4×3×2×1=1205 \times 4 \times 3 \times 2 \times 1 = 120 ways.
  2. There are 88 choices for first place, 77 for second and 66 for third: 8×7×6=3368 \times 7 \times 6 = 336 ways.

A product like 5×4×3×2×15 \times 4 \times 3 \times 2 \times 1 is written 5!5! and read "55 factorial." In general, n!n! is the number of ways to arrange nn different items in a row.

Definition

Factorial

For a whole number n≥1n \ge 1, n!=n×(n−1)×⋯×2×1n! = n \times (n - 1) \times \dots \times 2 \times 1. For example, 4!=4×3×2×1=244! = 4 \times 3 \times 2 \times 1 = 24.

Counting to find probability

Once you can count outcomes, probability follows: favorable outcomes over total outcomes.

Worked example: A random arrangement

The letters A, B, C and D are placed in a random order. What is the probability that they end up in alphabetical order?

There are 4!=244! = 24 possible orders, and only one of them is ABCD. The probability is 124\dfrac{1}{24}.

What is the probability that the arrangement starts with A? If A is fixed in the first spot, the other 33 letters can be arranged in 3!=63! = 6 ways. So the probability is 624=14\dfrac{6}{24} = \dfrac{1}{4}, which makes sense: each of the 44 letters is equally likely to come first.

Tip

When a stage has a restriction (like "the code must be odd" or "the first digit can't be 00"), fill in that stage first, then count the others.

Practice

Practice 1

Jordan has 44 shirts and 33 pairs of pants. How many different outfits of one shirt and one pair of pants can he make?

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 2

A pizza shop offers 33 crusts, 22 sauces and 55 toppings. How many different pizzas can you order with one crust, one sauce and one topping?

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 3

A coin is flipped 55 times, and the sequence of heads and tails is recorded. How many different sequences are possible?

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 4

In how many ways can the letters of the word MATH be arranged? (The arrangements don't have to be real words.)

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 5

A code is made of 33 digits chosen from 1,2,3,4,51, 2, 3, 4, 5, and no digit can be used twice. How many codes are possible?

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 6

A club has 1010 members. In how many ways can it choose a president, a vice president and a secretary, if no one can hold two offices?

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 7

A bike lock has 33 dials, each with the digits 00 to 99. If you guess a combination at random, what is the probability that you open the lock on your first try?

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 8

How many three-digit numbers (from 100100 to 999999) are odd and have no repeated digits?

Enter a number. Fractions like 3/4 and sqrt(2) are OK.