Suffix Tree - Dictionary Queries
You are given a string S, and Q queries. Each query consist of a string T. You have to determine if T is a substring of S.
|S| <= 10^5 Q <= 1000 |T| <= 1000
Input consist of A string S and an integer Q followed by Q strings
If T is a substring of S, print "y", else print "n"
2 abcdefghABCDEFGH 2 abc abAB xyz 1 xyz
y n y