I want to take a string:
x = 'The following is a string: \'Here is a nice python string\'
and split it, but keep the inner string intact so it returns:
['The', 'following', 'is', 'a', 'string:', '\'Here is a nice python string \'']
This should act the same for {}
or []
or ()
, however, not <>
.