1. A bag contains 5 green and 7 red jellybeans. How many ways can 5 jellybeans be withdrawn from the bag so that the number of green ones withdrawn will be less than 2?
There are two scenerios in which the number of green jellybeans will
be less than 2:
Scenerio 1) There are no green jellybeans withdrawn
Scenerio 2) There is one green jellybean and 4 red jellybeans
withdrawn
FiveRed <- choose (7,5) # scenerio 1
FourRed_OneGreen <- choose(7,4)*choose(5,1) # scenerio 2
answer = FiveRed + FourRed_OneGreen # add the number of ways together
answer
## [1] 196
2. A certain congressional committee consists of 14 senators
and 13 representatives. How many ways can a subcommittee of 5 be formed
if at least 4 of the members must be representatives?
Two scenerios:
Scenerio 1) All five members are representatives
Scenerio 1) Four members are representatives and one member is a
senator
FiveRep<- choose (13,5) # scenerio 1
FourRep_OneSen<- choose (14,1)*choose(13,4) # scenerio 2
answer<-FiveRep+FourRep_OneSen
answer
## [1] 11297
3)If a coin is tossed 5 times, and then a standard six-sided die is rolled 2 times, and finally a group of three cards are drawn from a standard deck of 52 cards without replacement, how many different outcomes are possible?
Coin<- choose(2,1)*choose(2,1)*choose(2,1)*choose(2,1)*choose(2,1) #also 2^5
Dice<- choose(6,1)*choose(6,1) #also 6^2
Card<- choose(52,1)*choose(51,1)*choose(50,1)
answer<-Coin*Dice*Card
answer
## [1] 152755200
4. 3 cards are drawn from a standard deck without replacement. What is the probability that at least one of the cards drawn is a 3? Express your answer as a fraction or a decimal number rounded to four decimal places.
This is without replacement.
To answer the question, one can find the probability that none of the
cards is a 3 and subtract by 1.
not_three<-(48/52*47/51*46/50) #48 because we are excluding the 3's
three<-1-not_three #subtract by 1
three
## [1] 0.2173756
5)Lorenzo is picking out some movies to rent, and he is
primarily interested in documentaries and mysteries. He has narrowed
down his selections to 17 documentaries and 14 mysteries.
Step 1. How many different combinations of 5 movies can he
rent?
answer<- choose (31,5)
answer
## [1] 169911
Step 2. How many different combinations of 5 movies can he rent if he wants at least one mystery?
one_myst <- choose (14,1)*choose (17,4) # 1 mystery
two_myst <- choose (14,2)*choose (17,3) # 2 mystery
three_myst<- choose (14,3)*choose (17,2) # 3 mystery
four_myst <- choose (14,4)*choose (17,1) # 4 mystery
five_myst <- choose (14,5) # 5 mystery
no<-one_myst+two_myst+three_myst+four_myst+five_myst
no
## [1] 163723
6) In choosing what music to play at a charity fund raising event, Cory needs to have an equal number of symphonies from Brahms, Haydn, and Mendelssohn. If he is setting up a schedule of the 9 symphonies to be played, and he has 4 Brahms, 104 Haydn, and 17 Mendelssohn symphonies from which to choose, how many different schedules are possible? Express your answer in scientific notation rounding to the hundredths place.
answer \(= 4.95 x 10^{8}\)
Brahms<-choose (4,3)
Haydn <-choose (104,3)
Mend <-choose (17,3)
answer<-Brahms*Haydn*Mend
answer
## [1] 495322880
7.) An English teacher needs to pick 13 books to put on his reading list for the next school year, and he needs to plan the order in which they should be read. He has narrowed down his choices to 6 novels, 6 plays, 7 poetry books, and 5 nonfiction books. Step 1. If he wants to include no more than 4 nonfiction books, how many different reading schedules are possible? Express your answer in scientific notation rounding to the hundredths place.
answer \(= 2.42 x 10^{6}\)
four_nf <- choose (5,4)*choose (19,9) #4 non-fiction books and 9 other book genres
three_nf <- choose (5,3)*choose (19,10) #3 non-fiction books and 10 other book genres
two_nf <- choose (5,2)*choose (19,11) #2 non-fiction books and 11 other book genres
one_nf <- choose (5,1)*choose (19,12) #1 non-fiction books and 12 other book genres
zero_nf <- choose (5,0)*choose (19,13) #0 non-fiction books and 13 other book genres
answer<-four_nf+three_nf+two_nf+one_nf+zero_nf
answer
## [1] 2420562
Step 2. If he wants to include all 6 plays, how many different reading schedules are possible? Express your answer in scientific notation rounding to the hundredths place.
answer<-choose(6,6)*choose(18,7) #6 plays and 7 other book genres
answer
## [1] 31824
8)Zane is planting trees along his driveway, and he has 5 sycamores and 5 cypress trees to plant in one row. What is the probability that he randomly plants the trees so that all 5 sycamores are next to each other and all 5 cypress trees are next to each other? Express your answer as a fraction or a decimal number rounded to four decimal places.
This is a permutation.
number of ways to order 5 sycamores trees=5!
number of ways to order 5 cypress trees=5!
number of ways 5 sycamores in a row can be ordered with 5 cypress tress
in a row=2!
number of ways the 10 trees can be ordered=10!
all <- (factorial(5)*factorial(5)*factorial(2))/factorial(10)
all
## [1] 0.007936508
format(all, scientific = TRUE)
## [1] "7.936508e-03"
9)If you draw a queen or lower from a standard deck of cards, I will pay you $4. If not, you pay me $16. (Aces are considered the highest card in the deck.
Step 1. Find the expected value of the proposition. Round your answer to two decimal places. Losses must be expressed as negative values.
answer <- round((4*(44/52)) - (16*(8/52)), digits=2)
answer
## [1] 0.92
Step 2. If you played this game 833 times how much would you expect to win or lose? Round your answer to two decimal places. Losses must be expressed as negative values.
answer_2 <- round((answer * 833),digits=2)
answer_2
## [1] 766.36