We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 81e239c commit 12422e1Copy full SHA for 12422e1
brain_games/scripts/brain_even.py
@@ -1,9 +1,10 @@
1
-import prompt
2
import random
3
+import prompt
4
+
5
6
def main():
- print('Welcome to the Brain Games!')
7
+ print('Welcome to the Brain Games!')
8
name = prompt.string("May I have your name? ")
9
print(f"Hello, {name}! "
10
f"Answer \'yes\' if the number is even, otherwise answer \'no\'.")
@@ -15,7 +16,8 @@ def main():
15
16
if answer == right_answer:
17
print('Correct!')
18
else:
- print(f"'{answer}' is wrong answer ;(. Correct answer was '{right_answer}'.\n"
19
+ print(f"'{answer}' is wrong answer "
20
+ f";(. Correct answer was '{right_answer}'.\n"
21
f"Let\'s try again, {name}!")
22
break
23
0 commit comments