program to implement a game

I have to write a program to implement a game that is played as follows:
• Start by hiding prizes in 4 treasure chests. One contains 500 chips, one contains 300 chips, one contains 100 chips, and one contains ‘you lose’.
• The person playing chooses a chest to open.
• The player may open chests until they choose to quit or until they open the chest with ‘you lose’.
• The goal is to win as much as the player can without opening ‘you lose’.
• Have different ending messages depending on how much the player wins or if they lose.

I am completely confused on how to assign the values to the chests then have the numbers randomized so they are not the same if the player chooses to play multiple times.
Topic archived. No new replies allowed.