regex - split string with equal sign at any location using python -


i split string equal sign @ location.

[in] example string abc=xyz example string

can please tell me how print string after equals sign ("="). instance, in above case, output should be

[out] abc=xyz

i got clue how split if ('=') if in last word not in anywhere inside string.

findall find occurances, (i assumed requirement)

import re = "[in] example string abc=xyz example string" print(re.findall("\w+=\w+",a)) 

op

['abc=xyz']


Comments

Popular posts from this blog

aws api gateway - SerializationException in posting new Records via Dynamodb Proxy Service in API -

asp.net - Problems sending emails from forum -