Carlo is trying to escape the barn, so he must find a password to the door.
Given a list $$$s$$$ of $$$n$$$ small strings, a password is acceptable if it's a subsequence of one of the strings in the list.
Given $$$m$$$ possible password, for each password, you should tell Carlo if it's acceptable or not.
The first line contains two integers $$$n$$$ $$$(1 \leq n \leq 5\times10^4)$$$.
The next $$$n$$$ lines contains the list $$$s$$$, the $$$i_{th}$$$ line contains the string $$$s_i$$$ $$$(1 \leq |s_i| \leq 6)$$$.
The next line contains one integer $$$m$$$ $$$(1 \leq m \leq 5\times10^4)$$$.
The next $$$m$$$ lines contains the possible password, each line contains a possible password $$$t$$$ $$$(1 \leq |t| \leq 6)$$$.
For each possible password, if it's acceptable, print "YES", otherwise print "NO".
3 ahmad abd jaun 6 jn ad acd aqd amh jan
YES YES NO NO NO YES