WEBVTT
00:00:01.970 --> 00:00:06.290
Today, we're going to do a fun
problem called rooks on a
00:00:06.290 --> 00:00:07.720
chessboard.
00:00:07.720 --> 00:00:11.770
And rooks on a chessboard is a
problem that's going to test
00:00:11.770 --> 00:00:15.010
your ability on counting.
00:00:15.010 --> 00:00:19.840
So hopefully by now in class,
you've learned a few tricks to
00:00:19.840 --> 00:00:21.300
approach counting problems.
00:00:21.300 --> 00:00:23.360
You've learned about
permutations, you've learned
00:00:23.360 --> 00:00:26.690
about k-permutations, you've
learned about combinations,
00:00:26.690 --> 00:00:29.160
and you've learned
about partitions.
00:00:29.160 --> 00:00:32.460
And historically for students
that we've taught in the past
00:00:32.460 --> 00:00:36.700
and many people, counting
can be a tricky topic.
00:00:36.700 --> 00:00:40.500
So this is just one drill
problem to help you get those
00:00:40.500 --> 00:00:43.450
skills under your belt.
00:00:43.450 --> 00:00:48.120
So what does the rooks on a
chessboard problem ask you?
00:00:48.120 --> 00:00:52.550
Well, you're given an 8-by-8
chessboard, which I've tried
00:00:52.550 --> 00:00:54.210
to draw here.
00:00:54.210 --> 00:00:55.350
It's not very symmetrical.
00:00:55.350 --> 00:00:57.770
Sorry about that.
00:00:57.770 --> 00:01:01.950
And you're told that you
have eight rooks.
00:01:01.950 --> 00:01:04.200
I'm sure most of you guys
are familiar with chess.
00:01:04.200 --> 00:01:08.210
But if any of you aren't,
chess is a
00:01:08.210 --> 00:01:09.790
sophisticated board game.
00:01:09.790 --> 00:01:12.780
And one of the types of pieces
you have in this game is
00:01:12.780 --> 00:01:13.840
called a rook.
00:01:13.840 --> 00:01:15.450
And in this particular problem,
00:01:15.450 --> 00:01:17.150
there are eight rooks.
00:01:17.150 --> 00:01:21.020
And your job is to place all
eight rooks onto this 8-by-8
00:01:21.020 --> 00:01:22.380
chessboard.
00:01:22.380 --> 00:01:26.880
Now, you're told in the problem
statement that all
00:01:26.880 --> 00:01:30.780
placements of rooks are
equally likely.
00:01:30.780 --> 00:01:38.030
And you are tasked with finding
the probability that
00:01:38.030 --> 00:01:39.630
you get a safe arrangement.
00:01:39.630 --> 00:01:42.920
So that is to say, you place
your eight rooks on the board.
00:01:42.920 --> 00:01:44.940
What is the probability
that the way you
00:01:44.940 --> 00:01:47.320
placed them is safe?
00:01:47.320 --> 00:01:49.160
So what do I mean by "safe"?
00:01:49.160 --> 00:01:55.900
Well, if you're familiar with
the way chess works, so if you
00:01:55.900 --> 00:01:59.770
place a rook here, it can move
vertically or it can move
00:01:59.770 --> 00:02:00.680
horizontally.
00:02:00.680 --> 00:02:03.360
Those are the only two
legal positions.
00:02:03.360 --> 00:02:07.250
So if you place a rook here
and you have another piece
00:02:07.250 --> 00:02:11.430
here, then this is not a safe
arrangement, because the rook
00:02:11.430 --> 00:02:14.804
can move this way
and kill you.
00:02:14.804 --> 00:02:18.010
Similarly, if you have a rook
here and another piece here,
00:02:18.010 --> 00:02:21.120
the rook can move horizontally
and kill you that way.
00:02:21.120 --> 00:02:25.870
So two rooks on this board are
only safe from each other if
00:02:25.870 --> 00:02:30.060
they are neither in the same
column nor in the same row.
00:02:30.060 --> 00:02:34.200
And that's going to be key for
us to solve this problem.
00:02:34.200 --> 00:02:37.690
So let's see-- where
did my marker go?
00:02:37.690 --> 00:02:39.410
I've been talking a lot,
and I haven't really
00:02:39.410 --> 00:02:40.520
been writing anything.
00:02:40.520 --> 00:02:47.050
So our job is again, to find the
probability that you get a
00:02:47.050 --> 00:02:50.100
safe arrangement.
00:02:50.100 --> 00:02:53.570
So I'm just going to do
"arrange" for short.
00:02:53.570 --> 00:02:56.760
Now, I talked about this
previously, and you guys have
00:02:56.760 --> 00:02:58.550
heard it in lecture.
00:02:58.550 --> 00:03:01.250
Hopefully you remember something
called the discrete
00:03:01.250 --> 00:03:03.000
uniform law.
00:03:03.000 --> 00:03:07.100
So the discrete uniform law is
applicable when your sample
00:03:07.100 --> 00:03:11.720
space is discrete and all
outcomes are equally likely.
00:03:11.720 --> 00:03:14.480
So let's do a quick
check here.
00:03:14.480 --> 00:03:17.500
What is our sample space
for this problem?
00:03:17.500 --> 00:03:21.510
Well, a logical choice would
be that the set of all
00:03:21.510 --> 00:03:26.070
possible outcomes is the set
of all possible spatial
00:03:26.070 --> 00:03:28.630
arrangements of rooks.
00:03:28.630 --> 00:03:33.140
And hopefully it's clear to
you that that is discrete.
00:03:33.140 --> 00:03:35.510
And the problem statement
furthermore gives us that
00:03:35.510 --> 00:03:37.080
they're equally likely.
00:03:37.080 --> 00:03:39.820
So the discrete uniform
law is in fact
00:03:39.820 --> 00:03:41.430
applicable in our setting.
00:03:41.430 --> 00:03:45.690
So I'm going to go ahead and
write what this means.
00:03:45.690 --> 00:03:50.320
So when your sample space is
discrete and all outcomes are
00:03:50.320 --> 00:03:53.740
equally likely, then you can
compute the probability of any
00:03:53.740 --> 00:03:58.500
event, A, simply by counting
the number of outcomes in A
00:03:58.500 --> 00:04:01.310
and then dividing it by the
total number of outcomes in
00:04:01.310 --> 00:04:02.820
your sample space.
00:04:02.820 --> 00:04:06.500
So here we just have to find
the number of total safe
00:04:06.500 --> 00:04:14.680
arrangements and then divide
it by the total number of
00:04:14.680 --> 00:04:15.930
arrangements.
00:04:17.990 --> 00:04:21.410
So again, as you've seen in
other problems, the discrete
00:04:21.410 --> 00:04:24.310
uniform law is really nice,
because you reduce the problem
00:04:24.310 --> 00:04:27.970
of computing probabilities to
the problem of counting.
00:04:27.970 --> 00:04:29.980
And so here's where we're
going to exercise those
00:04:29.980 --> 00:04:34.000
counting skills, as I
promised earlier.
00:04:34.000 --> 00:04:37.630
Now, I would like to start
with computing the
00:04:37.630 --> 00:04:40.370
denominator, or the total
number of arrangements,
00:04:40.370 --> 00:04:44.280
because I think it's a slightly
easier computation.
00:04:44.280 --> 00:04:46.775
So we don't care about the
arrangements being safe.
00:04:46.775 --> 00:04:49.700
We just care about
how many possible
00:04:49.700 --> 00:04:51.760
arrangements are there.
00:04:51.760 --> 00:04:55.190
Now, again, we have eight rooks,
and we need to place
00:04:55.190 --> 00:04:56.770
all of them.
00:04:56.770 --> 00:04:58.760
And we have this 8-by-8 board.
00:04:58.760 --> 00:05:02.670
So pretty quickly, you guys
could probably tell me that
00:05:02.670 --> 00:05:07.340
the total number of square
is 64, because this is
00:05:07.340 --> 00:05:10.950
just 8 times 8.
00:05:10.950 --> 00:05:16.130
Now, I like to approach
problems sequentially.
00:05:16.130 --> 00:05:18.490
That sort of really helps me
think clearly about them.
00:05:18.490 --> 00:05:22.330
So I want you to imagine a
sequential process during
00:05:22.330 --> 00:05:25.270
which we place each rook
one at a time.
00:05:25.270 --> 00:05:27.340
So pick a rook.
00:05:27.340 --> 00:05:29.450
The chessboard is
currently empty.
00:05:29.450 --> 00:05:35.725
So how many squares can you
place that rook in?
00:05:35.725 --> 00:05:37.090
Well, nobody's on the board.
00:05:37.090 --> 00:05:39.580
You can place it in 64 spots.
00:05:39.580 --> 00:05:47.635
So for the first rook that you
pick, there are 64 spots.
00:05:50.180 --> 00:05:53.790
Now, once you place this rook,
you need to place the second
00:05:53.790 --> 00:05:55.430
rook, because again, we're
not done until
00:05:55.430 --> 00:05:56.930
all eight are placed.
00:05:56.930 --> 00:06:00.650
So how many possible
spots are left.
00:06:00.650 --> 00:06:04.300
Well, I claim that there are 63,
because one rule of chess
00:06:04.300 --> 00:06:07.670
is that if you put a piece in
a particular square, you can
00:06:07.670 --> 00:06:09.550
no longer put anything
else on that square.
00:06:09.550 --> 00:06:12.080
You can't put two
or more things.
00:06:12.080 --> 00:06:16.650
So the first rook is occupying
one spot, so there's only 63
00:06:16.650 --> 00:06:18.320
spots left.
00:06:18.320 --> 00:06:25.360
So the second rook has 63 spots
that it could go in.
00:06:25.360 --> 00:06:31.680
Similarly, the third
rook has 62 spots.
00:06:31.680 --> 00:06:33.150
Hopefully you see the pattern.
00:06:33.150 --> 00:06:34.730
You can continue this down.
00:06:34.730 --> 00:06:37.310
And remember, we have to
place all eight rooks.
00:06:37.310 --> 00:06:40.330
So you could do it out
yourself or just
00:06:40.330 --> 00:06:42.030
do the simple math.
00:06:42.030 --> 00:06:46.560
You'll figure out that the
eighth rook only has 57 spots
00:06:46.560 --> 00:06:47.810
that it could be in.
00:06:51.610 --> 00:06:53.000
So this is a good start.
00:06:53.000 --> 00:06:56.460
We've sort of figured out if
we sequentially place each
00:06:56.460 --> 00:06:59.330
rook, how many options
do we have.
00:06:59.330 --> 00:07:03.910
But we haven't combined these
numbers in any useful way yet.
00:07:03.910 --> 00:07:08.265
We haven't counted the number
of total arrangements.
00:07:10.800 --> 00:07:13.690
And this may already be obvious
to some, but it wasn't
00:07:13.690 --> 00:07:16.130
obvious to me when I was first
learning this material, so I
00:07:16.130 --> 00:07:18.960
want to go through
this slowly.
00:07:18.960 --> 00:07:21.290
You have probably heard in
lecture by now about the
00:07:21.290 --> 00:07:22.930
counting principle.
00:07:22.930 --> 00:07:25.820
And what the counting principle
tells you is that
00:07:25.820 --> 00:07:30.430
whenever you have a process that
is done in stages and in
00:07:30.430 --> 00:07:35.430
each stage, you have a
particular number of choices,
00:07:35.430 --> 00:07:38.940
to get the total number of
choices available at the end
00:07:38.940 --> 00:07:42.420
of the process, you simply
multiply the number of choices
00:07:42.420 --> 00:07:43.670
at each stage.
00:07:45.950 --> 00:07:48.170
This might be clear to you,
again, simply from the
00:07:48.170 --> 00:07:49.860
statement, for some of you.
00:07:49.860 --> 00:07:51.980
But for others, it might
still not be clear.
00:07:51.980 --> 00:07:54.390
So let's just take
a simple example.
00:07:54.390 --> 00:07:56.870
Forget about the rook problem
for a second.
00:07:56.870 --> 00:07:59.520
Let's say you're at
a deli, and you
00:07:59.520 --> 00:08:00.940
want to make a sandwich.
00:08:00.940 --> 00:08:04.510
And to make a sandwich, you need
a choice of bread and you
00:08:04.510 --> 00:08:06.030
need a choice of meat.
00:08:06.030 --> 00:08:08.020
So we have a sandwich-building
process,
00:08:08.020 --> 00:08:09.160
and there's two stages.
00:08:09.160 --> 00:08:11.100
First, you have to pick the
bread, and then you have to
00:08:11.100 --> 00:08:12.260
pick the meat.
00:08:12.260 --> 00:08:15.270
So let's say for the choice
of bread, you can
00:08:15.270 --> 00:08:18.700
choose wheat or rye.
00:08:18.700 --> 00:08:22.270
So again, you can always use
a little decision tree--
00:08:22.270 --> 00:08:24.490
wheat or rye.
00:08:24.490 --> 00:08:26.480
And then let's say that
for the meats,
00:08:26.480 --> 00:08:27.840
you have three options.
00:08:27.840 --> 00:08:31.440
You have ham, turkey,
and salami.
00:08:31.440 --> 00:08:35.460
So you can have ham,
turkey, or salami--
00:08:35.460 --> 00:08:40.059
ham, turkey, or salami.
00:08:40.059 --> 00:08:43.210
How many total possible
sandwiches can you make?
00:08:43.210 --> 00:08:44.620
Well, six.
00:08:44.620 --> 00:08:48.320
And I got to that
by 2 times 3.
00:08:48.320 --> 00:08:51.130
And hopefully this makes sense
for you, because there's two
00:08:51.130 --> 00:08:54.220
options in the first stage.
00:08:54.220 --> 00:08:56.090
Freeze an option.
00:08:56.090 --> 00:08:58.410
Given this choice, there's
three options
00:08:58.410 --> 00:09:01.120
at the second stage.
00:09:01.120 --> 00:09:06.350
But you have to also realize
that for every other option
00:09:06.350 --> 00:09:09.450
you have at the first stage, you
have to add an additional
00:09:09.450 --> 00:09:11.770
three options for the
second stage.
00:09:11.770 --> 00:09:15.540
And this is the definition
of multiplication.
00:09:15.540 --> 00:09:19.260
If you add three two times,
you know that's 3 times 2.
00:09:19.260 --> 00:09:22.990
So if you extrapolate this
example to a larger, more
00:09:22.990 --> 00:09:26.620
general picture, you will have
derived for yourself the
00:09:26.620 --> 00:09:28.860
counting principle.
00:09:28.860 --> 00:09:33.800
And we're going to use the
counting principle here to
00:09:33.800 --> 00:09:36.970
determine what the total number
of arrangements are.
00:09:36.970 --> 00:09:40.650
So we have a sequential process,
because we're placing
00:09:40.650 --> 00:09:43.340
the first rook and then the
second rook, et cetera.
00:09:43.340 --> 00:09:48.810
So at the first stage,
we have 64 choices.
00:09:48.810 --> 00:09:53.550
At the second stage,
we have 63 choices.
00:09:53.550 --> 00:09:57.610
At the third stage, we have
62 choices, et cetera.
00:09:57.610 --> 00:10:01.000
And so I'm just multiplying
these numbers together,
00:10:01.000 --> 00:10:04.220
because the counting principle
says I can do this.
00:10:04.220 --> 00:10:10.320
So my claim is that this product
is equal to the total
00:10:10.320 --> 00:10:13.580
number of arrangements.
00:10:13.580 --> 00:10:17.540
And we could stop here, but I'm
going to actually write
00:10:17.540 --> 00:10:20.160
this in a more useful way.
00:10:20.160 --> 00:10:22.920
You guys should have
been introduced to
00:10:22.920 --> 00:10:24.510
the factorial function.
00:10:24.510 --> 00:10:29.800
So you can express this
equivalently as 64 factorial
00:10:29.800 --> 00:10:32.530
divided by 56 factorial.
00:10:32.530 --> 00:10:36.190
And this is not necessary for
your problem solution, but
00:10:36.190 --> 00:10:38.340
sometimes it's helpful to
express these types of
00:10:38.340 --> 00:10:41.170
products in factorials,
because you can see
00:10:41.170 --> 00:10:44.210
cancellations more easily.
00:10:44.210 --> 00:10:48.300
So if it's OK with everybody,
I'm going to erase this work
00:10:48.300 --> 00:10:51.580
to give myself more room.
00:10:51.580 --> 00:10:56.310
So we'll just put our answer for
the denominator up here,
00:10:56.310 --> 00:11:00.230
and then we're going to get
started on the numerator.
00:11:00.230 --> 00:11:04.170
So for the numerator, thanks to
the discrete uniform law,
00:11:04.170 --> 00:11:09.410
we only need to count the number
of safe arrangements.
00:11:09.410 --> 00:11:12.100
But this is a little bit more
tricky, because now, we have
00:11:12.100 --> 00:11:15.420
to apply our definition
of what "safe" means.
00:11:15.420 --> 00:11:18.440
But we're going to use the same
higher-level strategy,
00:11:18.440 --> 00:11:22.510
which is realizing that we can
place rooks sequentially.
00:11:22.510 --> 00:11:25.810
So we can think of it as
a sequential process.
00:11:25.810 --> 00:11:29.940
And then if we figure out how
many choices you have in each
00:11:29.940 --> 00:11:35.040
stage that sort of maintain the
"safeness" of the setup,
00:11:35.040 --> 00:11:37.680
then you can use the counting
principle to multiply all
00:11:37.680 --> 00:11:41.250
those numbers together
and get your answer.
00:11:41.250 --> 00:11:45.060
So we have to place
eight rooks.
00:11:45.060 --> 00:11:49.210
Starting the same way we did
last time, how many spots are
00:11:49.210 --> 00:11:52.880
there for the first rook
that are safe?
00:11:52.880 --> 00:11:56.520
Nobody is on the board yet, so
nobody can harm the first rook
00:11:56.520 --> 00:11:57.500
we put down.
00:11:57.500 --> 00:12:01.940
So I claim that it's just
our total of 64.
00:12:01.940 --> 00:12:04.050
Now, let's see what happens.
00:12:04.050 --> 00:12:05.740
Let's pick a random
square in here.
00:12:05.740 --> 00:12:08.520
Let's say we put our
first rook here.
00:12:08.520 --> 00:12:13.210
Now, I claim a bunch of spots
get invalidated because of the
00:12:13.210 --> 00:12:14.390
rules of chess.
00:12:14.390 --> 00:12:18.570
So before, I told you a rook can
kill anything in the same
00:12:18.570 --> 00:12:20.680
column or in the same row.
00:12:20.680 --> 00:12:25.020
So you can't put a rook here,
because they'll kill each
00:12:25.020 --> 00:12:27.250
other, and you can't
put a rook here.
00:12:27.250 --> 00:12:33.250
So by extension, you can see
that everything in the column
00:12:33.250 --> 00:12:36.970
and the row that I'm
highlighting in blue, it's no
00:12:36.970 --> 00:12:37.850
longer an option.
00:12:37.850 --> 00:12:39.880
You can't place a
rook in there.
00:12:39.880 --> 00:12:41.780
Otherwise, we will
have violated
00:12:41.780 --> 00:12:45.140
our "safety" principle.
00:12:45.140 --> 00:12:50.580
So where can our
second rook go?
00:12:50.580 --> 00:12:55.140
Well, our second rook can go in
any of the blank spots, any
00:12:55.140 --> 00:12:57.630
of the spots that are not
highlighted by blue.
00:12:57.630 --> 00:13:00.110
And let's stare at this
a little bit.
00:13:02.640 --> 00:13:06.560
Imagine that you were to take
scissors to your chessboard
00:13:06.560 --> 00:13:09.370
and cut along this line
and this line and this
00:13:09.370 --> 00:13:10.200
line and this line.
00:13:10.200 --> 00:13:14.190
So you essentially sawed off
this cross that we created.
00:13:14.190 --> 00:13:18.470
Then you would have four
free-floating chessboard
00:13:18.470 --> 00:13:23.070
pieces-- this one, this one,
this one, and this one.
00:13:23.070 --> 00:13:27.650
So this is a 3-by-4 piece,
this is 3-by-3, this is
00:13:27.650 --> 00:13:30.020
4-by-3, and this is 4-by-4.
00:13:30.020 --> 00:13:33.600
Well, because you cut this part
out, you can now slide
00:13:33.600 --> 00:13:36.000
those pieces back together.
00:13:36.000 --> 00:13:39.950
And hopefully you can convince
yourself that that would leave
00:13:39.950 --> 00:13:43.390
you with a 7-by-7 chessboard.
00:13:43.390 --> 00:13:48.650
And you can see that the
dimensions match up here.
00:13:48.650 --> 00:13:53.000
So essentially, the second rook
can be placed anywhere in
00:13:53.000 --> 00:13:55.970
the remaining 7-by-7
chessboard.
00:13:55.970 --> 00:14:00.280
And of course, there are 49
spots in a 7-by-7 chessboard.
00:14:00.280 --> 00:14:03.430
So you get 49.
00:14:03.430 --> 00:14:07.150
So let's do this experiment
again.
00:14:07.150 --> 00:14:11.860
Let me rewrite the reduced
7-by-7 chessboard.
00:14:11.860 --> 00:14:14.540
You're going to have to forgive
me if the lines are
00:14:14.540 --> 00:14:16.680
not perfect--
00:14:16.680 --> 00:14:22.760
one, two, three, four, five,
six, seven; one, two, three,
00:14:22.760 --> 00:14:23.210
four, five, six, seven.
00:14:23.210 --> 00:14:24.630
Yep, I did that right.
00:14:24.630 --> 00:14:32.030
And then we have one, two,
three, four, five, six, seven.
00:14:32.030 --> 00:14:36.800
That's not too bad for
my first attempt.
00:14:36.800 --> 00:14:39.980
So again, how did I get this
chessboard from this one?
00:14:39.980 --> 00:14:43.210
Well, I took scissors and I cut
off of the blue strips,
00:14:43.210 --> 00:14:46.690
and then I just merged the
remaining four pieces.
00:14:46.690 --> 00:14:50.160
So now, I'm placing
my second rook.
00:14:50.160 --> 00:14:54.350
So I know that I can place my
second rook in any of these
00:14:54.350 --> 00:14:58.770
squares, and it'll be
safe from this rook.
00:14:58.770 --> 00:15:00.830
Of course, in reality, you
wouldn't really cut up your
00:15:00.830 --> 00:15:01.390
chessboard.
00:15:01.390 --> 00:15:05.470
I'm just using this as a visual
aid to help you guys
00:15:05.470 --> 00:15:08.220
see why there are 49 spots.
00:15:08.220 --> 00:15:11.020
Another way you could see 49
spots is literally just by
00:15:11.020 --> 00:15:15.890
counting all the white squares,
but I think it takes
00:15:15.890 --> 00:15:17.720
time to count 49 squares.
00:15:17.720 --> 00:15:20.501
And this is a faster
way of seeing it.
00:15:20.501 --> 00:15:23.930
So you can put your second
rook anywhere here.
00:15:23.930 --> 00:15:26.340
Let's actually put in the
corner, because the corner is
00:15:26.340 --> 00:15:27.590
a nice case.
00:15:27.590 --> 00:15:30.700
If you put your rook in the
corner, immediately, all the
00:15:30.700 --> 00:15:35.360
spots in here and all the spots
in here become invalid
00:15:35.360 --> 00:15:38.230
for the third rook, because
otherwise, the rooks can hurt
00:15:38.230 --> 00:15:40.070
each other.
00:15:40.070 --> 00:15:45.130
So again, you'll see that if you
take scissors and cut off
00:15:45.130 --> 00:15:47.940
the blue part, you will have
reduced the dimension of the
00:15:47.940 --> 00:15:49.730
chessboard again.
00:15:49.730 --> 00:15:52.820
And you can see pretty quickly
that what you're left with is
00:15:52.820 --> 00:15:55.100
a 6-by-6 chessboard.
00:15:55.100 --> 00:16:02.820
So for the third rook, you get a
6-by-6 chessboard, which has
00:16:02.820 --> 00:16:06.020
36 free spots.
00:16:06.020 --> 00:16:08.880
And I'm not going to insult
your intelligence.
00:16:08.880 --> 00:16:11.280
You guys can see the pattern--
00:16:11.280 --> 00:16:13.130
64, 49, 36.
00:16:13.130 --> 00:16:16.310
These are just perfect
squares decreasing.
00:16:16.310 --> 00:16:21.740
So you know that the fourth
rook will have 25 spots.
00:16:21.740 --> 00:16:24.840
I'm going to come over here
because I'm out of room.
00:16:24.840 --> 00:16:27.970
The fifth rook will
have 16 spots.
00:16:27.970 --> 00:16:31.230
The sixth rook will
have nine spots.
00:16:31.230 --> 00:16:33.900
The seventh rook will
have four spots.
00:16:33.900 --> 00:16:37.780
And the eighth rook will
just have one spot.
00:16:37.780 --> 00:16:39.360
And now, here we're going
to invoke the
00:16:39.360 --> 00:16:40.880
counting principle again.
00:16:40.880 --> 00:16:43.930
Remember the thing that I just
defined to you by talking
00:16:43.930 --> 00:16:46.680
about sandwiches.
00:16:46.680 --> 00:16:49.240
And we'll see that to get
the total number of safe
00:16:49.240 --> 00:16:50.860
arrangements, we can
just multiply
00:16:50.860 --> 00:16:52.910
these numbers together.
00:16:52.910 --> 00:16:54.750
So I'm going to go ahead
and put that up here.
00:16:54.750 --> 00:17:02.360
You get 64 times 49 times
36 times 25 times 16
00:17:02.360 --> 00:17:05.079
times 9 times 4.
00:17:05.079 --> 00:17:07.810
And in fact, this
is our answer.
00:17:07.810 --> 00:17:10.859
So we're all done.
00:17:10.859 --> 00:17:15.630
So I really like this problem,
because we don't normally ask
00:17:15.630 --> 00:17:18.690
you to think about different
spatial arrangements.
00:17:18.690 --> 00:17:22.339
So it's a nice exercise, because
it lets you practice
00:17:22.339 --> 00:17:27.069
your counting skills in a
new and creative way.
00:17:27.069 --> 00:17:31.220
And in particular, the thing
that we've been using for a
00:17:31.220 --> 00:17:33.730
while now is the discrete
uniform law.
00:17:33.730 --> 00:17:36.730
But now, I also introduced
the counting principle.
00:17:36.730 --> 00:17:39.310
And we used the counting
principle twice--
00:17:39.310 --> 00:17:41.910
once to compute the numerator
and once to compute the
00:17:41.910 --> 00:17:44.210
denominator.
00:17:44.210 --> 00:17:49.480
Counting can take a long time
for you to absorb it.
00:17:49.480 --> 00:17:52.850
So if you still don't totally
buy the counting
00:17:52.850 --> 00:17:54.450
principle, that's OK.
00:17:54.450 --> 00:17:59.440
I just recommend you do some
more examples and try to
00:17:59.440 --> 00:18:02.280
convince yourself that it's
really counting the right
00:18:02.280 --> 00:18:04.020
number of things.
00:18:04.020 --> 00:18:07.510
So counting principle is
the second takeaway.
00:18:07.510 --> 00:18:10.520
And then the other thing that
is just worth mentioning is,
00:18:10.520 --> 00:18:12.980
you guys should get really
comfortable with these
00:18:12.980 --> 00:18:19.960
factorials, because they will
just show up again and again.
00:18:19.960 --> 00:18:21.960
So that's the end of the
problem, and I'll
00:18:21.960 --> 00:18:23.210
see you next time.