From an anonymous candidate: You are more recommended to use two pointers instead of dynamic programming to solve this problem during the interview
(This qustion is a variation of a LeetCode question 44. Wildcard Matching.)
Given an input string s and a pattern p, implement wildcard pattern matching with support for '*' where:
'*'Matches any sequence of characters (including the empty sequence).- The matching should cover the entire input string (not partial).
Constraints:
- 0 <=
s.length,p.length<= 2000 scontains only lowercase English letters.pcontains only lowercase English letters and'*'characters.
Ask AI Assistant

Ask AI Assistant
Ask me anything about this coding question!
Test Cases
Input
Output
Expected