Fixed Python

import random

a = random.randint(1,12) b = random.randint(1,12)

for i in range(10): question = "What is "+str(a)+" x "+str(b)+"? " answer = int(input(question)) if answer == a*b: print("Well done!") else: print("No.")

修复以下代码### Buggy Pythonimport Randoma = randomrandint112b = randomrandint112for i in range10 question = What is +a+ x +b+ answer = inputquestion if answer = ab print Well done! else

原文地址: https://www.cveoy.top/t/topic/02y 著作权归作者所有。请勿转载和采集!

免费AI点我,无需注册和登录