#icpc2014springj. [icpc2014spring_j]Unfair Game
[icpc2014spring_j]Unfair Game
MathJax.Hub.Config({ tex2jax: { inlineMath: [[""], ["\\(","\\)"]], processEscapes: true }}); blockquote { font-family: Menlo, Monaco, "Courier New", monospace; color: #333333; display: block; padding: 8.5px; margin: 0 0 9px; font-size: 12px; line-height: 18px; background-color: #f5f5f5; border: 1px solid #ccc; border: 1px solid rgba(0, 0, 0, 0.15); -webkit-border-radius: 4px; -moz-border-radius: 4px; border-radius: 4px; white-space: pre; white-space: pre-wrap; word-break: break-all; word-wrap: break-word; }
Problem Statement
Rabbit Hanako and Fox Jiro are great friends going to JAG primary school. Today they decided to play the following game during the lunch break.
This game is played by two players with heaps of some number of stones. The players alternatively take their turn to play the game. Jiro is a kind gentleman, so he yielded the first turn to Hanako. In each turn, the player must take some stones, satisfying the following conditions:
-
If the player is Hanako, she must take between to stones, inclusive, from a heap.
-
If the player is Jiro, he must take between to stones, inclusive, from a heap.
The winner is the player who takes the last stone. Jiro thinks it is rude to go easy on her because he is a perfect gentleman. Therefore, he does him best. Of course, Hanako also does so.
Jiro is worried that he may lose the game. Being a cadet teacher working at JAG primary school as well as a professional competitive programmer, you should help him by programming. Your task is to write a program calculating the winner, assuming that they both play optimally.
Input
The first line contains three integers , , and . () is the number of heaps. and () are the maximum numbers of stones that Hanako and Jiro can take in a turn, respectively. Then lines follow, each of which contains a single integer (), representing the number of stones in the -th heap at the beginning of the game.
Output
Output a line with "Hanako" if Hanako wins the game or "Jiro" in the other case.
Sample Input 1
3 5 4
3
6
12```
### Output for the Sample Input 1
```plain
Hanako```
* * *
### Sample Input 2
```plain
4 7 8
8
3
14
5```
### Output for the Sample Input 2
```plain
Jiro```
* * *
### Source Name
[Japan Alumni Group Spring Contest 2014](http://acm-icpc.aitea.net/index.php?2013%2FPractice%2F%BD%D5%A5%B3%A5%F3%A5%C6%A5%B9%A5%C8%2F%B0%C6%C6%E2)
* * *