Match Numbers and Letters of the Alphabet Issue

Match Numbers and Letters of the Alphabet Issue
0

#1

Tell us what’s happening:

What am i missing here?

Cannot read property ‘length’ of null is the error

Your code so far


let quoteSample = "Blueberry 3.141592653s are delicious.";
let myRegex = /h-s2-6/ig; // Change this line
let result = quoteSample.match(myRegex); // Change this line

Your browser information:

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

Link to the challenge:
https://learn.freecodecamp.org/javascript-algorithms-and-data-structures/regular-expressions/match-numbers-and-letters-of-the-alphabet


#2

Remember to use bracket notation like

let jennyStr = "Jenny8675309";
let myRegex = /[a-z0-9]/ig;
// matches all letters and numbers in jennyStr
jennyStr.match(myRegex);

To match a range.


#3

ahhh i feel so stupid. thanks so much :star_struck: