Henry and Derek are waiting on a room, eager to join the Snackdown 2016 Qualifier Round. They decide to pass the time by playing a game.  
In this game's setup, they write N positive integers on a blackboard. Then the players take turns, starting with Henry. In a turn, a player selects one of the integers, divides it by 2, 3, 4, 5 or 6, and then takes the floor to make it an integer again. If the integer becomes 0, it is erased from the board. The player who makes the last move wins.  

Henry and Derek are very competitive, so aside from wanting to win Snackdown, they also want to win this game. Assuming they play with the optimal strategy, your task is to predict who wins the game.  

-----Input-----
The first line of the input contains an integer T denoting the number of test cases. The description of T test cases follows.
The first line of each test case contains a single integer N denoting the number of integers they wrote on the board. The second line contains N space-separated integers A1, A2, ..., AN denoting the integers themselves.

-----Output-----
For each test case, output a single line containing either “Henry” or “Derek” (without quotes), denoting the winner of the game.

-----Constraints-----
- 1 ≤ T ≤ 1000
- 1 ≤ N ≤ 100
- 1 ≤ Ai ≤ 1018

-----Example-----
Input:2
2
3 4
3
1 3 5

Output:Henry
Derek

-----Explanation-----
Example case 1. In this test case, the numbers on the board are [3,4]. Henry can win by selecting 4 and then dividing it by 2. The integers on the board are now [3,2]. Derek now has a couple of choices:
- Derek can divide 2 by 3, 4, 5 or 6, making it 0 and removing it. Now only one integer remains on the board, 3, and Henry can just divide it by 6 to finish, and win, the game.
- Derek can divide 3 by 4, 5 or 6, making it 0 and removing it. Now only one integer remains on the board, 2, and Henry can just divide it by 6 to finish, and win, the game.
- Derek can divide 2 by 2. Now the integers are [1,3]. Henry can respond by dividing 3 by 3. The integers are now [1,1]. Now Derek has no choice but to divide 1 by 2, 3, 4, 5 or 6 and remove it (because it becomes 0). Henry can respond by dividing the remaining 1 by 2 to finish, and win, the game.
- Derek can divide 3 by 2 or 3. Now the integers are [1,2]. Henry can respond by dividing 2 by 2. The integers are now [1,1]. This leads to a situation as in the previous case and Henry wins.

Difficulty: UNKNOWN_DIFFICULTY

Starter code:

Solutions:
gb = [0, 1, 2, 2, 3, 3]
ga = [0 for x in range(70)]
gag = [0 for x in range(70)]
ga[0] = 1
gag[0] = 0
for i in range(1, 70):
	if i % 4 == 0:
		ga[i] = 1.5 * ga[i - 1]
		gag[i] = 0
	else:
		ga[i] = 2 * ga[i - 1]
		gag[i] = gag[i - 1] + 1

def g(n):
	if n < 6:
		return gb[n]
	else:
		x = n / 6
		a = 0
		for (i, k) in enumerate(ga):
			if k <= x:
				a = i
			else:
				break
		return gag[a]
t = int(input())
for q in range(t):
	n = int(input())
	a = list(map(int, input().split()))
	res = g(a[0])
	for i in range(1, n):
		res ^= g(a[i])
	if res == 0:
		print('Derek')
	else:
		print('Henry')


from math import floor
a = [0, 1, 2, 4, 6]
for i in range(1, 70):
	a.append(a[i] * 12)
b = []
for i in range(len(a)):
	b.append([a[i], i % 4])

def func(x):
	tot = 0
	for i in range(len(x)):
		for j in range(len(b) - 1):
			if x[i] >= b[j][0] and x[i] < b[j + 1][0]:
				tot ^= b[j][1]
				break
	return tot
t = eval(input())
for i in range(t):
	n = eval(input())
	x = list(map(int, input().split()))
	if func(x) == 0:
		print('Derek')
	else:
		print('Henry')


def g2(n):
	l = []
	while n:
		l.append(n % 12)
		n /= 12
	for x in reversed(l):
		if x >= 6:
			return 0
		if x >= 4:
			return 3
		if x >= 2:
			return 2
		if x >= 1:
			return 1
	return 0

def solve(n, a):
	r = 0
	for x in a:
		r ^= g2(x)
	return r
t = int(input())
for i in range(t):
	n = int(input())
	a = list(map(int, input().strip().split()))
	r = solve(n, a)
	if r == 0:
		print('Derek')
	else:
		print('Henry')


for _ in range(int(input())):
	n = int(input())
	a = [int(x) for x in input().split()]

	def nimber(game):
		if game <= 2:
			return game
		mx = 2
		nim = 2
		while True:
			if nim == 3:
				mx *= 3
				mx /= 2
			else:
				mx *= 2
			if game < mx:
				return nim
			nim += 1
			nim %= 4
	x = 0
	for aa in a:
		x ^= nimber(aa)
	if x != 0:
		print('Henry')
	else:
		print('Derek')