On 2015-11-21 18:49, david burstein wrote:
im pretty new in python and i didnt get how to use the re.split function.
for example if i have a string and i want to split it by two conditions:
first one splitting when " [ " appears second one when "]" appears

re.split(r" \[ |\]", string)

You need to escape the "[" because it normally indicates the start of a
character set.

--
https://mail.python.org/mailman/listinfo/python-list

Reply via email to