the-mysterious-wall
Source: hackerearth
Difficulty: UNKNOWN_DIFFICULTY

There was a very long wall outside a kingdom. There were many gates in the wall. Each gate is labelled with any alphabet characters between a to z(Multiple gates could have same label). Also, every person has their name as only one character ( Many persons could have same name ). To enter into the Kingdom there are few rule.
    1. One can go through the gate whose label matches with his name.
    2. All gates are opened at the beginning of each day, and once if a person passes through a gate, that gate is closed for the rest of the day.

A group of people visits the kingdom today. On knowing this strange rule, they look for a contiguous gates through which they all could go through. As they are already tired in travelling a long distance to come here, they ask for your help.

Note : All of them should pass through the gates at the same time. Do not consider of people waiting for the next day so that a gate will be opened.

Input : 
First line contains T - No. of Test cases.
For each test case - First line contains S1 - sequence of characters represents labels of gate.
Second line contains S2 - sequence of characters the name of the people(s).

Output : 
Print " YES " if they can go into the kingdom else "NO" in separate lines. (Without quotes)

Constraints :
1 ≤ T ≤ 500 
1 ≤ | S1 | ≤ 10^5
1 ≤ | S2 | ≤ 10^5 
Sum of all | S1 | , | S2| over all test cases ≤ 8*10^6

SAMPLE INPUT
4
aaaaa
a
abcde
bc
querty
eur
visamo
ao

SAMPLE OUTPUT
YES
YES
YES
NO