isMatch("ab", ".*") → true
is this right?? . is 'a', *can 'b'/??
* means zero of more of the preceding element, so in this case zero or more dots, and .. does match ab.
Does that mean if p equals to ".*" the function will always return true?
Yes, that's right.
Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.