aa=re.sub(r'NGC','',aa)
aa=re.sub(r'NGG','',aa)
match1=re.match(r'(.*) SSN (\d+)',aa)
match2=re.match(r'(.*) S(\d+)', aa)
if match1:
aa=match1.group(1)+' '+'Season'+' '+match1.group(2)
if match2:
aa=match2.group(1)+' '+'Season'+' '+match2.group(2)
print aa
Returned value:
Wicked Tuna Season 5
No comments:
Post a Comment