99999久久久久久亚洲,欧美人与禽猛交狂配,高清日韩av在线影院,一个人在线高清免费观看,啦啦啦在线视频免费观看www

熱線電話:13121318867

登錄
2019-04-12 閱讀量: 653
python中函數(shù)的用法

如果兩個(gè)輸入中的任何一個(gè)為1,則或門給出輸出1,否則給出0。

# Python3 progarm to illustrate

# working of OR gate

def OR(a, b):

if a == 1:

return True

elif b == 1:

return True

else:

return False

# Driver code

if __name__=='__main__':

print(OR(0, 0))

print("+---------------+----------------+")

print(" | OR Truth Table | Result |")

print(" A = False, B = False | A AND B =",OR(False,False)," | ")

print(" A = False, B = True | A AND B =",OR(False,True)," | ")

print(" A = True, B = False | A AND B =",OR(True,False)," | ")

print(" A = True, B = True | A AND B =",OR(True,True)," | ")

0.0000
2
關(guān)注作者
收藏
評(píng)論(0)

發(fā)表評(píng)論

暫無(wú)數(shù)據(jù)
推薦帖子