Question: Can i get some help in this making it a underworld or heavens theme in C + + , some of the code is below.
Can i get some help in this making it a underworld or heavens theme in C some of the code is below. Thanks
#include
#include
#include
using namespace std;
int main
Secret word and word progress
string secretword "CERBERUS";
char wordprogresssecretword.length;
fillwordprogress, wordprogress secretword.length;
Other variables
int guessesremaining ;
string hangmanart original hangman art; Replace with your artwork
Game loop
while guessesremaining && stringwordprogress secretword
Display information
cout hangmanart endl;
cout wordprogress endl;
cout "Guesses remaining: guessesremaining endl;
Get player input
char guess;
cout "Enter your guess az: ;
cin guess;
Handle guess
bool found false;
for int i ; i secretword.length; i
if toupperguess touppersecretwordi
wordprogressi guess;
found true;
if found
guessesremaining;
hangmanart OK; Update artwork
WinLose condition
if stringwordprogress secretword
cout "You win! The word was: secretword endl;
else
cout "You lose! The word was: secretword endl;
return ;
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
