The first line contains one integer, denoting the number of test cases.
For each test case:
The first line contatins three integers, denoting the size of the game region and the number of sparks.
Followinglines each contains four integers
, denoting the parameters of given sparks.
It's guaranteed that.
Output one-string
of length
in one line where
iff such autowinning point exists in case
while
iff no such points.