One day, a librarian wants to pick up
4
distinct books from a particular bookshelf, and that bookshelf has
1
0
distinct books arranged in a line. In how many ways can she select four books such that no consecutive books from the shelf are chosen?
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Let the books be A , B , C , D , E , then their placement is as such: − A − B − C − D − E −
where each bar between A and E denote a nonzero number of books.
Let these bars be denoted as v , w , x , y , z for integers, v , z ≥ 0 , w , x , y ≥ 1
Which satisfy the equation v + w + x + y + z = 1 0 − 4 = 6
Let w ′ = w − 1 , x ′ = x − 1 , y ′ = y − 1 , then we need to calculate the non negative solution for v + w ′ + x ′ + y ′ + z = 3 which is simply ( 3 5 + 3 − 1 ) = 3 5
Let the books be numbered from 1 to 1 0 . There are 9 pairs of consecutive books possible ( { 1 , 2 } , { 2 , 3 } , . . . , { 9 , 1 0 } ) .
Total number of ways to choose 4 books = 1 0 C 4
Total number of ways to choose 4 books such that it has at least one consecutive pair = 9 C 1 × 2 ! 8 × 7
Explanation : For a given consecutive book pair { a , a + 1 } , the 3 r d book can be chosen in 8 and the 4 t h book can be chosen in 7 ways. And there are total 9 C 1 ways to choose a consecutive pair.
Total number of ways to choose 4 books such that it has at least two consecutive pairs = 9 C 2 + 8 C 1 × 6
Explanation : There are two ways of choosing two consecutive pairs, viz. non-overlapping and overlapping case.
non-overlapping case :
e.g. { 1 , 2 , 7 , 8 } has two non-overlapping consecutive pairs viz. { 1 , 2 } and { 7 , 8 } . There are 9 C 2 ways of choosing two non-overlapping consecutive pairs.
overlapping case :
e.g. { 1 , 2 , 3 , 8 } has 2 overlapping consecutive pairs viz. { 1 , 2 } and { 2 , 3 } . There are 8 overlapping consecutive pairs possible which are { 1 , 2 , 3 } , { 2 , 3 , 4 } , . . . , { 8 , 9 , 1 0 } . For a given overlapping consecutive pair, there are 7 ways to choose the remaining 4 t h book. However, one choice of the 4 t h book makes the two overlapping pair case as two non-overlapping consecutive pairs case as well. Hence this 1 choice has already been counted in the non-overlapping case discussed above. e.g. for the overlapping case { 1 , 2 , 3 , − } , choosing 4 as the 4 t h book introduces non-overlapping case as well i.e. { 1 , 2 } and { 3 , 4 } . Hence there are effectively 6 ways to choose the 4 t h book.
Total number of ways to choose 4 books such that it has at least three consecutive pairs = 7 C 1
This is possible only when all the four books are consecutive, e.g. { 1 , 2 , 3 , 4 } , { 2 , 3 , 4 , 5 } , . . . , { 7 , 8 , 9 , 1 0 } .
Using principle of exclusion-inclusion:
Total ways of choosing books such that no consecutive books are chosen = 1 0 C 4 − ( 9 C 1 × 2 ! 8 × 7 − 9 C 2 − 8 C 1 × 6 + 7 C 1 ) = 2 1 0 − ( 9 × 2 8 − 3 6 − 4 8 + 7 ) = 2 1 0 − 1 7 5 = 3 5
Problem Loading...
Note Loading...
Set Loading...
The same problem can be interpret into the following :
The bookshelf has 6 distinct books and you have 4 books to put in between them such that there is no books among the 4 is consecutive. How many ways can you do that?
Since there are 7 gaps and 4 books to put in to, there are ( 4 7 ) ways