Sentinel Goodbye

A "sentinel value" in a program is a value that indicates the end of a series. In a loop, when the sentinel value is reached, the loop finishes repeating.

Write a project 21-SentinelGoodbye that asks people to enter their name. Every time a name is entered the program prints a personalized "Hello" greeting using their name. If the user hits [Enter] without entering a name, however--a sentinel value of "" (the "empty string")--the program says "Goodbye" and ends.

Sample Interaction

Enter your name: Joe
Hi Joe!
Enter your name: Lizzie
Hi Lizzie!
Enter your name: Ani
Hi Ani!
Enter your name: ([Enter] with no name given)
Goodbye!

Finishing Up

Once your program is working correctly, use your mouse to click-drag over the URL address for your project at the top of the browser window. Copy that link, and give that copied link to the instructor using the procedure given in class.