Tell us what’s happening:
Hello I’m working on the regular expression
and I have done Lazy Matching task
below is my solution and there isn’t any problem
let text = "<h1>Winter is coming</h1>";
let myRegex = /<[h1]*?>/; // Change this line
let result = text.match(myRegex);
But I try also more simple solution and test shows me that I solved it but there isn’t any lazy matching
I just thinking that there is a little bug, because I can do it without any lazy solution
<p>
let myRegex = /<h1>/;
</p>
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.119 Safari/537.36
.
Link to the challenge:
https://learn.freecodecamp.org/javascript-algorithms-and-data-structures/regular-expressions/find-characters-with-lazy-matching