Randomized Game VBA Coding

insta_hista

New Member
Joined
Nov 9, 2017
Messages
2
Can somebody please help me code the following question? I don't know where to begin and desperately need help. If somebody could help me code this I will be so very appreciative.

A coffee shop is giving away a prize by selling coffee cups with a letter placed under each cup’s rim. To win the prize, you must collect cups with letters that spell the name, HORVATH. In production, letters are randomly selected and placed under the rims of the cups. Create a program that does the following:
(a) Animates the selection of cup letters. Keeps selecting coffee cups until all seven of the necessary letters have been collected and displays the number of cups purchased in order to win the prize. (Letters should be randomly and independently selected from the alphabet when inserted under the rims of the coffee cups.)
(b) Performs this simulation several times (without the animation) to determine, on the average, how many coffee cups need to be bought in order to win the prize. Your program should prompt the user to provide the number of simulation runs required.
(c) How much would the prize need to be worth in order to play the game without losing money on all the cups of coffee purchased? (Assume that each coffee costs $1.00.) Note: You can determine this via the coding from (b) and then have your program write the result on your spreadsheet.
 

Excel Facts

Why does 9 mean SUM in SUBTOTAL?
It is because Sum is the 9th alphabetically in Average, Count, CountA, Max, Min, Product, StDev.S, StDev.P, Sum, VAR.S, VAR.P.
Sounds like homework to me...
 
Upvote 0
I am not against helping with homework, but I won't do the homework. Can you show us what you have so far and where you are hung up?
 
Upvote 0

Forum statistics

Threads
1,224,827
Messages
6,181,195
Members
453,021
Latest member
pingpong7117

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top