|시간 제한||메모리 제한||제출||정답||맞은 사람||정답 비율|
|1 초||128 MB||0||0||0||0.000%|
Herbert is a game in which you control a robot on an infinite two-dimensional grid. There are three commands available to you:
After playing this game for a while, you wonder how many squares you can reach within a certain number of moves. Write a program to calculate the answer to this question.
On the first line an integer t (1 ≤ t ≤ 100): the number of test cases. Then for each test case:
For each test case:
4 0 1 2 3
1 2 5 11