Regular Expressions 101

Community Patterns

Community Library Entry

0

Regular Expression
Python

r"
(?:(?P<EngDate>[a-zA-Z]+\s)??(?P<Date0>(?<!\.)(?:\d{1,2}(?=[,\s.\/-])|\d{4}))\.??(?(1),?)(?P<d_sep>[\s.\/-])?(?:(?P<Date1>[^\W\d_]+|\d{1,2})(?P=d_sep))?(?(1)[0-2]?\d(?::\d{2}){1,2}\s\w+\s)(?P<Date2>\d{2}|\d{4})(?!:|\d))|(?P<Time>(?<![\+-0])[0-2]?\d(?:\:[0-6]\d){1,2}(?:[,\.]\d{3,6})?)
"
g

Description

Trying out based on list of these formats

Submitted by anonymous - 4 years ago