New extension: Quantifiers (grep)

The next extension for the grep challenge is now live: Quantifiers.

Quantifiers let you match characters or expressions based on how many times they appear.

By the end of this extension, your grep implementation will support repetition patterns like:

Quantifier Meaning Example Pattern Matches
* 0 or more times a* “”, “a”, “aa”, “aaa”…
{n} Exactly n times b{2} “bb”
{n,} n or more times c{2,} “cc”, “ccc”, “cccc”…
{n,m} Between n and m times d{1,3} “d”, “dd”, “ddd”

Here’s the stage breakdown:

Please give this a try and let us know how it can be improved! @UdeshyaDhungana (author of this extension) and I will be available here to help out with any tester or instruction-related issues.

3 Likes