#ABC476B. 通配符 / Wild Card
通配符 / Wild Card
Problem Statement
is a string of length consisting of lowercase English letters.
is a string of length consisting of lowercase English letters and *.
We say that matches if and only if can be made equal to by replacing each * in with some lowercase English letter.
Determine whether matches .
Constraints
- is a string of length consisting of lowercase English letters.
- is a string of length consisting of lowercase English letters and
*.
Input
The input is given from Standard Input in the following format:
Output
Output Yes if matches , and No otherwise, in one line.
8
chokudai
**o*u*ai
Yes
By replacing the first, second, fourth, and sixth characters of , which are *, with c, h, k, and d, respectively, can be made equal to .
5
snuke
snake
No
5
yiwiy
*****
Yes
- Source: AtCoder ABC 476 B
相关
在下列比赛中: