Regular Expressions - Specify Upper and Lower Number of Matches

Tell us what’s happening:
Something is incorrect with debug tools, since test functions only care about whether your string has enough “h” or not.

Your code so far

let ohStr = "Ohhh no";
let ohRegex = /h{3,6}/g; // Change this line
let result = ohRegex.test(ohStr);
console.log(result)

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/113.0.0.0 Safari/537.36

Challenge: Regular Expressions - Specify Upper and Lower Number of Matches

Link to the challenge:

Hi there and welcome to the forum!
I’m not sure I understand your comment.
Your code doesn’t pass the challenge, because it doesn’t match the required phrases.
Did you have a question about this challenge?

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.