Skip to content

Tag Archives: regular-expression

Prerequisite –  Finite automata, Regular expressions, grammar, and language. In this article, we will see some popular regular expressions and how we can convert them… Read More
Given a string str and a word w, the task is to print the number of the occurrence of the given word in the string… Read More
In this article, we will know How to clone a regular expression using JavaScript. We can clone a given regular expression using the constructor RegExp().… Read More
Given a string with space-separated or camel case or snake case letters, the task is to find the kebab case of the following string.  For… Read More
Given two strings text and pattern of length M and N respectively, the task is to check if the pattern matches the text or not.… Read More
Given a string S, the task is to move all the digits present in the string, to the beginning of the string. Examples: Input: S… Read More
Given a string S, the task is to find and extract all the URLs from the string. If no URL is present in the string,… Read More
Given a string str, the task is to extract the substrings present between two delimiters, i.e. ‘[‘ and ‘]’. Examples: Input: str = “[This is… Read More
Prerequisite – Introduction of Finite Automata Non-Deterministic Finite Automata and ∈-Non-Deterministic Finite Automata are almost the same except for their transition function and there are… Read More
State Elimination Method : Rules to convert a DFA/NFA//Ɛ-NFA into corresponding Regular Expression. Arden’s Method is not capable of converting Ɛ-NFA. By state elimination method… Read More
Given a string str of length N and a substring pattern of length M, the task is to find the frequency of occurrences of pattern… Read More
Given a string email that denotes an Email Address, the task is to check if the given string is a valid email id or not.… Read More
Given string str of length N, the task is to remove uppercase, lowercase, special, numeric, and non-numeric characters from this string and print the string… Read More
Given string str of length N, the task is to check if the given string contains only special characters or not. If the string contains… Read More
Given string str of length N, the task is to check whether the given string contains uppercase alphabets, lowercase alphabets, special characters, and numeric values… Read More