Commit 1282aa77 by BellCodeEditor

save project

parent 9f6c1ac4
Showing with 27 additions and 13 deletions
whille True:
i=input("你要输几位数?(2~4位都可以哦!)")
if i=="两位数 " or "2位数":
j=int(input("乘数1是什么?"))
k=int(input("乘数2是什么?"))
d=(j*k)
print(j,'*',k,'=',d)
elif i=="三位数 " or "3位数":
j=int(input("乘数1是什么?"))
k=int(input("乘数2是什么?"))
d=(j*k)
print(j,'*',k,'=',d)
while True:
i=input("你要输几位数?(2~4位都可以哦!)")
if i=="两位数 " or "2位数":
j=int(input("乘数1是什么?"))
k=int(input("乘数2是什么?"))
d=(j*k)
print(j,'*',k,'=',d)
elif i=="三位数 " or "3位数":
j=int(input("乘数1是什么?"))
k=int(input("乘数2是什么?"))
e=int(input("乘数3是什么?"))
d=(j*k*e)
print(j,'*',k,'*',e,'=',d)
elif i=="四位数 " or "4位数":
j=int(input("乘数1是什么?"))
k=int(input("乘数2是什么?"))
e=int(input("乘数3是什么?"))
a=int(input("乘数4是什么?"))
d=(j*k*e*a)
print(j,'*',k,'*',e,'*',a,'=',d)
else:
print("请重新输入")
\ No newline at end of file
i=1
for j in range(1,10):
prin(j,'*',k,'=',j*i,end=" ")
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment