I used a different way to separate the code. Is it still proper practice or is the way he separated it more proper?
string GetGuess() {
string Guess = “”;
// get a guess from the player
cout << "Enter your guess: ";
getline(cin, Guess);
return Guess;
}
void PrintGuess() {
// repeat the guess back to them
cout << "Your guess was: " << GetGuess() << endl;
return;
}
void PlayGame() {
// loops the guesses
for (int i = 1; i <= TOTAL_GUESSES; i++) {
PrintGuess();
cout << endl;
}
return;
}