..
C++ Language
1. Write a program toroll a random character. Declare an enum with all the differentcharacter types in
your game. Then use the rand()to generate a random number betweenthe min and max values of your
enum (e.g. if you have 4 character classes, then enum values are 0,1, 2, 3). Finally, depending on the type
of character that was randomly selected, generate the rest of thestats, either randomly or hardcoded.
Example Output
Press enter to roll a random character…
Type: Warrior
HP: 93
MP: 1
Expert Answer
An answer will be send to you shortly. . . . .