import getpass
age = getpass.getpass('Enter your age:')
print("Entered age is: " + age)
Player 1 enters his age, and Player 2 tries to guess it. Reponse from the computer is either "Lower" or "Higher" depending on Player 2's guess, until Player 2 gets it right.
Player 1 enter your age:
Player 2 enter your guess: 20
Nope! Lower: 16
Nope! Higher: 18
Nope! Lower: 17
17 is correct!
Player 1 enters a secret word and Player 2 tries to guess it. After every wrong guess, the computer highlights which letters Player 2 got right.
Player 1 enter your secret word:
Player 2 enter your guess: banana
Nope! You got these letters right: _a_a_a
Guess again: pineapple
Nope! You got these letters right: p__eapple
Guess again: apple
apple is correct!