diff --git a/regexps.qmd b/regexps.qmd index 946b2e0..7b9be47 100644 --- a/regexps.qmd +++ b/regexps.qmd @@ -607,9 +607,9 @@ Spaces and new lines are ignored, as is everything after `#`. phone <- regex(r"( \(? # optional opening parens (\d{3}) # area code - [) -]? # optional closing parens, space, or dash + [)\ -]? # optional closing parens, space, or dash (\d{3}) # another three numbers - [ -]? # optional space or dash + [\ -]? # optional space or dash (\d{3}) # three more numbers )", comments = TRUE)