I  — Dice

Time Limit: 1 sec
Memory Limit: 32 MB

Mary add Sue are playing with dices. Rules are simple: at the begging each of them puts coin on the table and roll a dice. Wins a player who rolled a larger number. If numbers are the same, coins stay on the table for a next round. In order to make this game more interesting they decided to play now with normal dices, but with dice that can have arbitrary number of bones, from 0 till 9. However each round must be played with same dice by both players.

Girls have been playing this game for a day long, till Mary run out of coins (nevertheless she had more coins at the beginning of the game). Now Mary is confused. How could she have lost all her coins? She thinks that Sue had been cheating. Before each roll Mary wrote on a paper numbers of bones on each side of the dice. Now she wonders if same dice was always used during one round. Help her to find it out.

INPUT

On the first line there is the total number of test cases T (T ≤ 103), next T lines follows. Each line contains two six digit numbers, each digit stands for number of bones on side of a dice in this order: top, bottom, front, left, back, right.

OUTPUT

For each test case output line "Equal" if two dices are equals, or "Not Equal" otherwise.

SAMPLE INPUT

3
345678 345678
123123 123456
123456 351624

SAMPLE OUTPUT

Equal
Not Equal
Equal

Problem by: Aleksej Viktorchik; Leonid Sislo
Huge Easy Contest #2