Given an input string (s) and a pattern (p), implement wildcard pattern matching with support for '?' and '*' where: '?' Matches any single character. '*' Matches any sequence of characters (including the empty sequence).
30:00
Java
Wildcard Matching
hard
Topics
Companies
Given an input string (s) and a pattern (p), implement wildcard pattern matching with support for '?' and '' where: '?' Matches any single character. '' Matches any sequence of characters (including the empty sequence).
Example 1:
Input: {"s":"aa","p":"*"}
Output: true
Constraints:
0≤s.length,p.length≤2000
s consists of lowercase English letters.
p consists of lowercase English letters, '?', and '*'.