RegExp {X,} quantifier
Definition and Usage
n{X,} quantifier matches strings containing at least Xnsequence.
Xmust be numeric.
grammar
new RegExp("n{X,}")
或者更简单方式:
/n{X,}/
或者更简单方式:
/n{X,}/
Browser Support
All major browsers support {X,} quantifier
Examples
Examples
It contains at least three digits of the sequence of a global search for a substring:
var str="100, 1000 or 10000?";
var patt1=/d{3,}/g;
var patt1=/d{3,}/g;
The marked text below shows where the expression gets a match:
100 , 1000 or 10000 ?
try it"
JavaSript RegExp objects