Skip to content

Commit

Permalink
fix: correctly mention the range of n in quantifier expression (#33525
Browse files Browse the repository at this point in the history
)
  • Loading branch information
jasonren0403 committed May 11, 2024
1 parent e29bc9f commit 95a838d
Showing 1 changed file with 4 additions and 5 deletions.
Expand Up @@ -71,7 +71,7 @@ Quantifiers indicate numbers of characters or expressions to match.
</td>
<td>
<p>
Where "n" is a positive integer, matches exactly "n" occurrences of
Where "n" is a non-negative integer, matches exactly "n" occurrences of
the preceding item "x". For example, <code>/a{2}/</code> doesn't match
the "a" in "candy", but it matches all of the "a"'s in "caandy", and
the first two "a"'s in "caaandy".
Expand All @@ -84,7 +84,7 @@ Quantifiers indicate numbers of characters or expressions to match.
</td>
<td>
<p>
Where "n" is a positive integer, matches at least "n" occurrences of
Where "n" is a non-negative integer, matches at least "n" occurrences of
the preceding item "x". For example, <code>/a{2,}/</code> doesn't
match the "a" in "candy", but matches all of the a's in "caandy" and
in "caaaaaaandy".
Expand All @@ -97,9 +97,8 @@ Quantifiers indicate numbers of characters or expressions to match.
</td>
<td>
<p>
Where "n" is 0 or a positive integer, "m" is a positive integer, and
<code><em>m</em> > <em>n</em></code
>, matches at least "n" and at most "m" occurrences of the preceding
Where "n" and "m" are non-negative integers and <code>m >= n</code>,
matches at least "n" and at most "m" occurrences of the preceding
item "x". For example, <code>/a{1,3}/</code> matches nothing in
"cndy", the "a" in "candy", the two "a"'s in "caandy", and the first
three "a"'s in "caaaaaaandy". Notice that when matching "caaaaaaandy",
Expand Down

0 comments on commit 95a838d

Please sign in to comment.