同学代码里面的这些都是什么语句啊?
s = set([name.lower() for name in ['Adam', 'Lisa', 'Bart', 'Paul']])
print 'adam' in s
print 'bart' in s
L=['Adam', 'Lisa', 'Bart', 'Paul']
M=[]
for x in L:
y=x.lower()
M.append(y)
s = set(M)
print 'adam' in s
print 'bart' in s
s = set([name.lower() for name in ['Adam', 'Lisa', 'Bart', 'Paul']])
print 'adam' in s
print 'bart' in s
L=['Adam', 'Lisa', 'Bart', 'Paul']
M=[]
for x in L:
y=x.lower()
M.append(y)
s = set(M)
print 'adam' in s
print 'bart' in s
2018-07-13
举报