1 #!/usr/bin/env python3 2 L1 = ['Hello', 'World', 18, 'Apple', None] 3 L2 = [s.lower() for s in L1 if isinstance(s, str)] 4 print L2 ~
Sign in to make a reply
我要吃白菜网