Created
November 14, 2018 12:43
-
-
Save titaneric/0a9856c5c05cbc5083525d742ed6bb33 to your computer and use it in GitHub Desktop.
To tomdannis @ptt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
l = ["1060501", "1. AAA 2. BBB", "ID1234", "1060502", "1. BBB", "ID0000"] | |
selected_list = [l[i] for i in range(0, len(l), 3) if "AAA" in l[i+1]] | |
print(selected_list) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment