How do I do an "OR" for my python regex? -
re.compile("abc") i "abc" or "xyz".
use |:
re.compile("abc|xyz") it's worth perusing regular-expression.info detailed information regular expression howto , re — regular expression operations python documentation.
Comments
Post a Comment