#P14100. [ZJCPC 2017] Cooking Competition

[ZJCPC 2017] Cooking Competition

题目描述

"Miss Kobayashi's Dragon Maid" is a Japanese manga series written and illustrated by Coolkyoushinja. An anime television series produced by Kyoto Animation aired in Japan between January and April 20172017.

In episode 88, two main characters, Kobayashi and Tohru, challenged each other to a cook-off to decide who would make a lunchbox for Kanna's field trip. In order to decide who is the winner, they asked nn people to taste their food, and changed their scores according to the feedback given by those people.

There are only four types of feedback. The types of feedback and the changes of score are given in the following table.

$$\begin{array}{|c|c|c|c|} \hline \text{Type} & \text{Feedback} & \text{Score Change} & \text{Score Change} \\ & & \text{(Kobayashi)} & \text{(Tohru)} \\ \hline 1 & \text{Kobayashi cooks better} & +1 & 0 \\ \hline 2 & \text{Tohru cooks better} & 0 & +1 \\ \hline 3 & \text{Both of them are good at cooking} & +1 & +1 \\ \hline 4 & \text{Both of them are bad at cooking} & -1 & -1 \\ \hline \end{array}$$

Given the types of the feedback of these nn people, can you find out the winner of the cooking competition (given that the initial score of Kobayashi and Tohru are both 00)?

输入格式

There are multiple test cases. The first line of input contains an integer TT (1T1001 \le T \le 100), indicating the number of test cases. For each test case:

The first line contains an integer nn ( 1n201 \le n \le 20), its meaning is shown above.

The next line contains nn integers a1,a2,,ana_1, a_2, \dots , a_n (1ai41 \le a_i \le 4), indicating the types of the feedback given by these nn people.

输出格式

For each test case output one line. If Kobayashi gets a higher score, output "Kobayashi" (without quotes). If Tohru gets a higher score, output "Tohru" (without quotes). If Kobayashi's score is equal to that of Tohru's, output "Draw" (without quotes).

3
3
1 2 1
2
2 4
2
3 4
Kobayashi
Tohru
Draw

提示

For the first test case, Kobayashi gets 1+0+1=21 + 0 + 1 = 2 points, while Tohru gets 0+1+0=10 + 1 + 0 = 1 point. So the winner is Kobayashi.

For the second test case, Kobayashi gets 01=10 - 1 = -1 point, while Tohru gets 11=01 - 1 = 0 point. So the winner is Tohru.

For the third test case, Kobayashi gets 11=01 - 1 = 0 point, while Tohru gets 11=01 - 1 = 0 point. So it's a draw.