My current script is not finding what I am looking for. I’m trying to look through a text document for strings in the format eg CP3_001_0010 that may appear in a longer string of text such as *VFX;CP3_001_0010;
match = re.search(r"(*?CP3_d{3,4}[A-Z]?d{4})", line)
am I missing something here?
submitted by /u/th3whistler
[link] [comments]
r/learnpython My current script is not finding what I am looking for. I’m trying to look through a text document for strings in the format eg CP3_001_0010 that may appear in a longer string of text such as *VFX;CP3_001_0010; match = re.search(r”(*?CP3_d{3,4}[A-Z]?d{4})”, line) am I missing something here? submitted by /u/th3whistler [link] [comments]
My current script is not finding what I am looking for. I’m trying to look through a text document for strings in the format eg CP3_001_0010 that may appear in a longer string of text such as *VFX;CP3_001_0010;
match = re.search(r"(*?CP3_d{3,4}[A-Z]?d{4})", line)
am I missing something here?
submitted by /u/th3whistler
[link] [comments]