regex how to match all the strings which character x repeated for 5n times -
how write regex each following case:
match string character x repeated 0 or 5 times,e.g. abc or abcxxxxx pass;
match strings character x repeated 5n times, example: xxxxx,xxxxxxxxxx,xxxxxxxxxxxxxxx... pass
thank remarkable answers!! sorry obscurity of previous question, point how use iteration of regex, say, if want character x repeated 5^n times
i guess want this:
/(?:x{5})*/
example
Comments
Post a Comment