i have a string as below
strng ="Fiscal Year Ended March 31, 2018 Total Year (in $000's)"
if the above string has a year substring (e.g.. 2014,2015 etc), separate out the 'year' substring and the rest.
for getting the 'year' i am using
re.findall(r"\b20[012]\d\b",strng)
how can i get the rest of the substring also. expected output is
year_substring --> '2018'
rest --> 'Fiscal Year Ended March 31, Total Year (in $000's)'
is there any way to get both using regex?