Presentation Error

No attempts yetTime limit1sMemory limit128 MB

Problem

Write a program that decides whether two strings are the same string once presentation (output-format) differences are taken into account, or whether they are fundamentally different strings.

Every input string consists only of the following characters:

  • Uppercase or lowercase English letters
  • Digits
  • Spaces (the space bar, not tabs)
  • Special symbols

The special symbols are:

( ) [ ] { } . , ; :

Two strings are considered the same string apart from presentation according to the following rules:

  • Uppercase and lowercase letters are not distinguished.
  • The number (amount) of consecutive spaces does not matter. However, if one string has a space where the other has none — that is, a difference in the mere presence or absence of a space — the strings are considered different.
  • Spaces at the very beginning or the very end of a string do not matter, whether present or not.
  • Spaces immediately before or immediately after a special symbol also do not matter, whether present or not.
  • Opening brackets ((, [, {) are not distinguished from one another.
  • Closing brackets (), ], }) are not distinguished from one another.
  • A comma , and a semicolon ; are not distinguished from each other.

Input

The first line contains the number of test cases $K$.

Each test case is then given over two lines: string $s_1$ followed by string $s_2$.

Each string has length at most $1000$, and no string contains a newline character.

Output

For each test case, first print Data Set K: , where $K$ is the 1-based test-case number.

Then print equal if the two strings are the same once presentation is taken into account, or not equal if they are different strings no matter how the presentation is adjusted.

Print one blank line between consecutive test cases.