Regular Expressions 101

Community Library

Community Library Entry

-2

Regular ExpressionOpen Workspace

r"
,(?![^\[\]]*(?:\([^[]]]*\])?\])|,(?![^\{\}]*(?:\([^\{\}]]*\})?\})|\{|\}
"
g

Description
Created·2015-10-23 16:41
Type·Match
Flavor·Python

matches only those commas that are between sets, or between members of a set. does not match commas that are inside members.

Submitted by Amrit Kohli
Open Workspace