我试图用单词AND满足if语句中的2个条件,但似乎不起作用。有什么不对?我基本上是想打印e1,e2和e3中最大的一个。
if e1 > e2 AND e3:
then print elapsed 1
elif:
e2>e3
then print e2
else:
print e3
答案 0 :(得分:0)
您需要说
if e1 > e2 and e1 > e3:
print(e1)
elif e2 > e3:
print(e2)
else:
print(e3)
然后它将起作用。