python 逻辑运算符问题

1 正确

if'A' not in self.storageDevice.softVersion or\
     'B' not in self.storageDevice.softVersion or\
     'C' not in self.storageDevice.softVersion or\
     'D' not in self.storageDevice.softVersion ) 

 

2.错误

 

if'A' or 'B' or 'C' or 'D' not in self.storageDevice.softVersion) 

 

posted @ 2018-02-26 16:44  夜歌乘年少  阅读(242)  评论(0编辑  收藏  举报