I have the following example text:
60CC
60 cc
60cc2
60CC(2)
and the following regex to match these instances:
(60\s?(cc)(\w|\(.\)){0,5})
however my output is as follows for the first match:
Match 1
1. 60CC
2. CC
3. None
this example can be seen at: https://pythex.org/?regex=(60%5Cs%3F(cc)(%5Cw%7C%5C(.%5C))%7B0%2C5%7D)&test_string=60CC%0A60%20cc%0A60cc2%0A60CC(2)&ignorecase=1&multiline=0&dotall=0&verbose=0
how do I limit the output to just #1 ?
I am using Python Regex. the snippet of my python code is:
re.findall("(60\s?(cc)(\w|\(.\)){0,5})", text, flags=re.IGNORECASE)