C. Super Binary Numbers
time limit per test
1 second
memory limit per test
256 megabytes
input
standard input
output
standard output

Amir, believes in binary numbers. After solving lots of binary-boy problems, He managed to come up with a problem about binary numbers.

The problem is as follows :

Amir calls a number super binary number if it has at least two of the following properties :

  • the number is palindrome in hexadecimal presentation.
  • the number is palindrome in binary presentation.
  • the number is palindrome in decimal presentation.

Your job is to help Amir to determine if a number is a super binary number or not.

Input

The first line of input shows the number of test cases $$$t$$$ :

$$$1 \le t \le 10^3$$$.

Each of following $$$t$$$ lines contains an integer $$$n$$$ :

$$$1 \le n \le 10^3$$$.

Output

For each test case, if the number is a super binary number print "ghavi", otherwise print "fanni khordim".

Example
Input
3
85
69
17
Output
ghavi
fanni khordim
ghavi
Note

Testcase $$$1$$$ :

$$$85 = (1010101)_2 \rightarrow Palindrome$$$.

$$$85 = (55)_{16} \rightarrow Palindrome$$$.