Skip to content
Snippets Groups Projects
Commit e6694d6b authored by vand's avatar vand
Browse files

Upload New File

parent 8714c147
No related branches found
No related tags found
No related merge requests found
print('Welcome to multiplication game!')
print('(Empty to quit)')
import random
s = 'start'
while not s == '':
a = random.randint(0, 9)
b = random.randint(0, 9)
s = input(f'{a}*{b}=')
if not s=='':
try:
p = int(s)
if p == a*b:
print('Good job!')
else:
print('Oh, no, try again.')
except:
print("I don't understand that.")
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment