
- HTML Tutorial
- HTML - Home
- HTML - Overview
- HTML - Basic Tags
- HTML - Elements
- HTML - Attributes
- HTML - Formatting
- HTML - Phrase Tags
- HTML - Meta Tags
- HTML - Comments
- HTML - Images
- HTML - Tables
- HTML - Lists
- HTML - Text Links
- HTML - Image Links
- HTML - Email Links
- HTML - Frames
- HTML - Iframes
- HTML - Blocks
- HTML - Backgrounds
- HTML - Colors
- HTML - Fonts
- HTML - Forms
- HTML - Embed Multimedia
- HTML - Marquees
- HTML - Header
- HTML - Style Sheet
- HTML - Javascript
- HTML - Layouts
- HTML References
- HTML - Tags Reference
- HTML - Attributes Reference
- HTML - Events Reference
- HTML - Fonts Reference
- HTML - ASCII Codes
- ASCII Table Lookup
- HTML - Color Names
- HTML - Entities
- HTML - Fonts Ref
- HTML - Events Ref
- MIME Media Types
- HTML - URL Encoding
- Language ISO Codes
- HTML - Character Encodings
- HTML - Deprecated Tags
Match any string containing a sequence of N p's
To match any string containing a sequence of N p’s with JavaScript RegExp, use the p{N} Quantifier.
Example
You can try to run the following code to match any string containing a sequence of N p’s −
<html> <head> <title>JavaScript Regular Expression</title> </head> <body> <script> var myStr = "Welcome 1, 100, 10000, 1000"; var reg = /\d{3}/g; var match = myStr.match(reg); document.write(match); </script> </body> </html>
- Related Articles
- Match any string containing a sequence of two to three p's.
- Match any string containing a sequence of at least two p's.
- Match any string containing zero or more p's.
- Match any string containing at most one p.
- Match any string containing one or more p's with JavaScript RegExp.
- Match any string with p at the end of it.
- Match any string with p at the beginning of it.
- Select rows containing a string in a specific column with MATCH and AGAINST in MySQL
- How to match any one uppercase character in python using Regular Expression?\n\n
- How to match any non-digit character in Python using Regular Expression?\n\n
- In the adjoining figure, $P R=S Q$ and $S R=P Q$.a) Prove that $\angle P=\angle S$.b) $\Delta SOQ \cong \Delta POR$."\n
- How to match at the end of string in python using Regular Expression?\n\n
- In the figure, common tangents \( P Q \) and \( R S \) to two circles intersect at \( A \). Prove that \( P Q=R S \)."\n
- How to match a line not containing a word in Java Regex
- Regex to match lines containing multiple strings in Java

Advertisements