Two good friends Mrinmay and Anup are fighting for the same girl. The girl being sapiosexual gave them a task to accomplish. The person who accomplishes the task goes out with her.Mrinmay, tired of being a "Sakht Launda", doesn't want to lose her to "Stud Launda" Anup.
Help Mrinmay to complete the task.
INPUT
First line contains a String Str
Second line contains number of Queries N
Each of the next N lines contains a string query.
NOTE: All characters of the all strings are lowercase.
Task: For each query, determine whether the string can be formed using the characters of the original string
OUTPUT
For each query ,Print "YES" if the query string can be formed from the letters of String Str else Print "NO"
CONSTRAINTS
0 < length of string < 100
0 < number of queries< 10^5
0 <length of query string< 100