Regular Expression Matching Problem
Regular Expression Matching Problem — ExecCode Hard DSA Practice
Solve the Regular Expression Matching problem on ExecCode. Free online hard DSA practice in DP. Write and run code in Java, C++, Python — no signup required to run.
Problem description
Given a string s and pattern p, implement regex matching with support for '.' and '' where '.' matches any single character and '' matches zero or more of the preceding element. Matching must cover the entire string.
Examples
Input s = "aab", p = "cab"; Output true
Constraints
1 ≤ s.length ≤ 20 1 ≤ p.length ≤ 30
Practice Regular Expression Matching free on ExecCode. Browse DSA problems, topic map, and placement guides.