NFA
user_5119020710
python
2 years ago
497 B
10
Indexable
#bai 1 import re f = open("B1.txt") S = f.read().split("\n") for e in S: if re.match(r"(^[tc])", e): if re.findall(r"re\w*", e): print(e) f.close() #Bai 2 import re f = open("B1.txt") S = f.read().split("\n") for e in S: if re.search(r"[a-z0-9A-Z].{25}", e): print(e) f.close() #bai 3 import re f = open("B1.txt") S = f.read().split("\n") for e in S: if re.search(r"[?!]$", e): print(e) f.close()
Editor is loading...