I am trying to write a regular expression that will match any number of a certain character within a certain order of characters. In example:
“ssssnnnowww” would match to “snow”
but
“sssnnnsssooooowwww” would not match to “snow”
I have tried the following:
/[s][n][o][w]/g // no luck
/s*n*o*w*/ // no luck
Try this regular expression: