# Simulation and randomness: Random digit tables

We can simulate events involving randomness like picking names out of a hat using tables of random digits. Tables of random digits can be used to simulate a lot of different real-world situations. Here's $2$ lines of random digits we'll use in this worksheet:
Line $1$: $96565\,\, 05007\,\, 16605\,\, 81194\,\, 14873\,\, 04197\,\, 85576\,\, 45195$
Line $2$: $11169\,\, 15529\,\, 33241\,\, 83594\,\, 01727\,\, 86595\,\, 65723\,\, 82322$
Things to know about random digit tables:
• Each digit is equally likely to be any of the $10$ digits $0$ through $9$.
• The digits are independent of each other. Knowing about one part of the table doesn't give away information about another part.
• The digits are put in groups of $5$ just to make them easier to read. The groups and rows have no special meaning. They are just a long list of random digits.

## Problem 1: Getting a random sample

There are $90$ students in a lunch period, and $5$ of them will be selected at random for cleaning duty every week. Each student receives a number $01-90$ and the school uses a random digit table to pick the $5$ students as follows:
• Start at the left of Line $1$ in the random digits provided.
• Look at $2$-digit groupings of numbers.
• If the 2-digit number is anything between $01$ and $90$, that student is assigned lunch duty. Skip any other $2$-digit number.
• Skip a $2$-digit number if it has already been chosen.
Line $1$: $~96565\,\, 05007\,\, 16605\,\, 81194\,\, 14873\,\, 04197\,\, 85576\,\, 45195$
Which $5$ students should be assigned cleaning duty?

## Problem 2: Doing a simulation

A cereal company is giving away a prize in each box of cereal and they advertise, "Collect all $6$ prizes!" Each box of cereal has $1$ prize, and each prize is equally likely to appear in any given box. Caroline wonders how many boxes it takes, on average, to get all $6$ prizes.
She decides to do a simulation using random digits as follows:
• Start at the left of Line $2$ in the random digits provided.
• Look at single digit numbers.
• The digits $1-6$ represent the different prizes.
• She ignores the digits $0, 7, 8, 9$.
• One trial of the simulation is done when all $6$ digits have appeared.
• At the end of the trial, she counts how many digits it took for every digit $1-6$ to appear (ignoring the other digits).
Line $2$: $~11169\,\, 15529\,\, 33241\,\, 83594\,\, 01727\,\, 86595\,\, 65723\,\, 82322$
question a
How many boxes of cereal did it take to get all $6$ prizes?
boxes
question b
Caroline did some more trials of her simulation. Each trial, she recorded how many boxes it took to get all $6$ prizes. Her results are shown in the table below.
Trial #Number of boxes
$1$$12$
$2$$17$
$3$$15$
$4$$7$
$5$$20$
On average, how many boxes of cereal did it take Caroline to get all $6$ prizes?
Caroline's friend Grant did his own simulation. He did his just like Caroline, but he did $20$ trials instead of $5$. On average, it took him $14.8$ boxes to get all $6$ prizes.
Whose results are more likely to give a closer estimate to the true average number of boxes it takes to get all $6$ prizes?