Practice
문제
John practiced for days in preparation for the olympiad. He solved tasks on day .
After the olympiad he wanted to know whether there was a span of consecutive days when he solved exacly tasks. In other words, are there integers and such that and ?
Write a program to help John answer that question.
입력
The first line of input contains , the number of days (), and , the number of questions ().
The second line contains space-separated integers (, where ), the numbers of tasks John solved each day.
The third line contains space-separated integers (, where ), the numbers of tasks in John's questions.
출력
Output lines, one per question. On the line output the word 'JAH', if there exists a span of consecutive days when John solved exactly tasks, or the word 'EI', if there's no such span of days.
예제
예제 1
3 4 1 2 3 2 7 5 4
JAH EI JAH EI