Question: Create a fully - functional game of roulette, that actuall Create a fully - functional game of roulette, that actually plays! Write an interactive code
Create a fullyfunctional game of roulette, that actuall
Create a fullyfunctional game of roulette, that actually plays!
Write an interactive code that does the following:
a Asks the user to enter a starting amount of funds
b Then asks the user which game they would like to play number color, etc.
c Then asks the user which subgame they would like to play redblack oddeven etc.
d Then asks the user how much they would like to bet on that game
e Generates a random number. Note: You will also need to include and
f Determines whether or not the user is a winner
g Determines the new value of funds
h Asks the user if they would like to play again, but without asking them for a new starting amount of funds. The funds from the last game must carry over
Requirements
a A bet that is larger than the available funds must request the user to reenter a new bet amount
b The display must show the user their Account Balance while placing a bet amount
c The display must show the user their odds and payout percentage of the current bet BEFORE the random number is drawn
d Once the number is drawn, the display must show the actual winnings of every possible bet. For Example:
i Number:
ii Color: Black
iii. OoE: Even
iv Column:
v Thirds:
vi Halves:
e The user must be able to play over and over until they are out of Available Funds, at which point they would be requested to add additional funds.
f If the user selects not to play again, a simple display saying "Thank you for Playing" will be shown and the game will end.
RecomMENDations hints
You can choose to create this program in a single script, but you can also use userdefined functions to simplify
You can choose to use normal DISP functions, or can you research a more interactive method such as:
questdlg creates a dialog box for asking questions to the user
inputdlg creates a dialog box for getting text from a user
Other functions that may assist you include:
randi generates random integers
strdouble, numstr strcat changes variable types or merges text strings
ismember determines if a variablevalue exists within an array
Create a fullyfunctional game of roulette, that actually plays!
Write an interactive code that does the following:
a Asks the user to enter a starting amount of funds
b Then asks the user which game they would like to play number color, etc.
c Then asks the user which subgame they would like to play redblack oddeven etc.
d Then asks the user how much they would like to bet on that game
e Generates a random number. Note: You will also need to include and
f Determines whether or not the user is a winner
g Determines the new value of funds
h Asks the user if they would like to play again, but without asking them for a new starting amount of funds. The funds from the last game must carry over
Requirements
a A bet that is larger than the available funds must request the u
Write an interactive code that does the following:
a Asks the user to enter a starting amount of funds
b Then asks the user which game they would like to play number color, etc.
c Then asks the user which subgame they would like to play redblack oddeven etc.
d Then asks the user how much they would like to bet on that game
e Generates a random number. Note: You will also need to include and
f Determines whether or not the user is a winner
g Determines the new value of funds
h Asks the user if they would like to play again, but without asking them for a new starting amount of funds. The funds from the last game must carry over
Requirements
a A bet that is larger than the available funds must request the user to reenter a new bet amount
b The display must show the user their Account Balance while placing a bet amount
c The display must show the user their odds and payout percentage of the current bet BEFORE the random number is drawn
d Once the number is drawn, the display must show the actual winnings of every possible bet. For Example:
i Number:
ii Color: Black
iii. OoE: Even
iv Column:
v Thirds:
vi Halves:
e The user must be able to play over and over until they are out of Available Funds, at which point they would be requested to add additional funds.
f If the user selects not to play again, a simple display saying "Thank you for Playing" will be shown and the game will end.
RECOMMENDATIONS HinTS
You can choose to create this program in a single script, but you can also use userdefined functions to simplify
You can choose to use normal DISP functions, or can you research a more interactive method such as:
questdlg creates a dialog box for asking questions to the user
inputdlg creates a dialog box for getting text from a user
Other functions that may assist you include:
randi generates random integers
strdouble, numstr strcat changes variable types or merges text strings
ismember determines if a variablevalue exists within an array
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
