scrimba
Learn Regex
Find Characters with Lazy Matching
Go Pro!Bootcamp

Bootcamp

Study group

Collaborate with peers in your dedicated #study-group channel.

Code reviews

Submit projects for review using the /review command in your #code-reviews channel

Find Characters with Lazy Matching
AboutCommentsNotes
Find Characters with Lazy Matching
Expand for more info
index.js
run
preview
console
let string = "titanic";
let regex = /t[a-z]*i/;
string.match(regex);

let text = "<h1>Winter is coming</h1>";
let myRegex = /<.*>/;
let result = text.match(myRegex);

console.log(result);
Console
index.html
-3:17