交作业
Topic sourceL1 = ['Hello', 'World', 18, 'Apple', None] L2 = [] for n in L1: if isinstance(n,str) == True: L2.append(n) L2 = [n.lower() for n in L2] print(L2)
- 1
L1 = ['Hello', 'World', 18, 'Apple', None] L2 = [] for n in L1: if isinstance(n,str) == True: L2.append(n) L2 = [n.lower() for n in L2] print(L2)
方糖米菲
L = ['Hello', 'World', 18, 'Apple', None] L2 = [] for n in L: if isinstance(n,str) == True: L2.append(n) print(L2)