কাইজি ও চেয়ারম্যানের খেলা ( Kaiji’s Last Ordeal )

CPU: 1s
Memory: 1024MB


কাইজি ও চেয়ারম্যান হৌদৌ একটি খেলা খেলে। খেলাটি M টি সারি এবং N টি কলাম বিশিষ্ট একটি দ্বিমাত্রিক গ্রিডে খেলা হয়। গ্রিডের প্রতিটি ব্লক হয় সাদা নয় কাল। শুরুতে তারা গ্রিডের দুইটি ব্লকে দৈবভাবে অবস্থান নেয়। তারা একজনের পর আরেকজন এভাবে দান দেয়। প্রথম দানটি দেয় কাইজি। কোন খেলোয়াড়ের প্রতিটি দানে সে যেই ব্লকে আছে তার রঙ পরিবর্তিত হয় (সাদা হতে কাল, অথবা কাল হতে সাদা); তাছাড়াও পার্শ্ববর্তী একই রঙের ব্লকগুলির রঙও পরিবর্তিত হয়। একইভাবে ঐ ব্লকগুলির পার্শ্ববর্তী একই রঙের ব্লকগুলির রঙও পরিবর্তিত হয় এবং এভাবে চলতে থাকে। দুইটি ব্লক পার্শ্ববর্তী হয় যদি তাদের একটি সাধারণ দেয়াল থাকে (প্রতিটি ব্লকের সর্বোচ্চ চারটি পার্শ্ববর্তী ব্লক থাকতে পারে - ব্লকটির উপরে, নীচে, ডানে এবং বামে। কোণার ব্লকগুলির দুইটি পার্শ্ববর্তী ব্লক থাকে। অন্যান্য প্রান্তবর্তী ব্লকগুলির তিনটি পার্শ্ববর্তী ব্লক থাকে। )। লক্ষ্য কর যে একজন খেলোয়াড় কখনই সে শুরুতে যেই ব্লকে ছিল, সেই ব্লক ছেড়ে যায় না। প্রতি দানে শুধু উপরে বর্ণিত উপায়ে কিছু ব্লকের রঙ পরিবর্তিত হয় মাত্র। যে খেলোয়াড় প্রথমে অপর খেলোয়াড়ের ব্লকের রঙ পরিবর্তন করতে পারে, সেই খেলায় জয়ী হয়। এই সমস্যাটিতে দ্বিমাত্রিক গ্রিডটিকে 0 এবং 1 এর ম্যাট্রিক্স হিসেবে প্রকাশ করা হয় (0 মানে সাদা, 1 মানে কাল)। কাইজি এবং চেয়ারম্যানের অবস্থান দেওয়া থাকবে। তোমাকে খেলায় জয়ী কে হবে তা নির্ণয় করতে হবে। বুঝার সুবিধার জন্য নীচে খেলাটির কিছু দান দেখানো হল।

এখানে, শুরুতে কাইজি গাঢ়ভাবে 1 লিখা ব্লকে (সারি 4, কলাম 7) ও চেয়ারম্যান গাঢ়ভাবে 0 লিখা ব্লকে (সারি 1, কলাম 4) অবস্থান নেয়। প্রথমে কাইজি দান দেয় এবং তারপর তারা একজনের পরে আরেকজন এভাবে দান দেয়। খেলার চতুর্থ এবং শেষ দানে কাইজির ব্লকের রঙ পরিবর্তন করার মাধ্যমে চেয়ারম্যান জয়লাভ করে।


Being enraged by Kaiji’s tricky victory at the Pachinko, chairman Hyoudou orders his subordinates to capture Kaiji immediately. Once Kaiji is brought, Hyoudou forces him to bet his life one last time. If Kaiji wins, he walks away with Hyoudou’s fortune; if he loses, he loses his life. The game is played on a grid with M rows and N columns. Each cell of the grid is either black or white. Initially, Kaiji and Hyoudou each walks blindfolded to two different cells at random. Kaiji and Hyoudou alternate moves; Kaiji moves first.

On a player’s move, the color of the cell under his feet is flipped (i.e. from black to white or from white to black); any adjacent cell with the same color is flipped as well. And this process is repeated for their adjacent cells with the same color and so on. Note that, two cells are adjacent if they share a side. Thus, a cell may have maximum four adjacent cells. A cell on a sideline has three and a cell at a corner has only two adjacent cells.

Notice that a player does not actually move all over the place. He always remains in his initial cell. Only the described cells flip color during his move. The first player who is able to flip the color of the opponent’s cell wins the game. We represent the grid as a matrix of 0s and 1s (0 means white and 1 means black cell). The positions of Kaiji and Hyoudou in the grid are also given. We show the steps of a sample game for clarity.

Here, initially Kaiji is in the cell with the bold 1 (row 4, column 7) and Hyoudou is in the cell with the bold 0 (row 1, column 4). Kaiji moves first and they alternate moves. At the fourth and final move of the game, Hyoudou wins by flipping the color of Kaiji’s cell. Kaiji has no way to know, what underhanded trick might be performed by the sinister chairman of the underworld during the blindfold walk. In a game of seemingly pure chance with no room for strategy and the players not moving a muscle, will Kaiji’s luck carry him through? Or, will the chairman’s evil laughter echo throughout the room?


ইনপুটের বর্ণনা

ইনপুটের প্রথম লাইনে টেস্টকেসের সংখ্যা T (1 <= T <= 30). T test cases follow. Each will consist of one line containing two integers M (numbe** দেওয়া থাকবে। এর পরে T টি টেস্টকেসের বর্ণনা থাকবে, যেখানে 1 <= M, N <= 100। প্রতিটি টেস্টকেসের প্রথম লাইনে দুইটি পূর্ণসংখ্যা M (সারির সংখ্যা) এবং N (কলামের সংখ্যা) দেওয়া থাকবে। পরবর্তী M লাইনে স্পেস দিয়ে আলাদা করা N টি পূর্ণসংখ্যা (0 অথবা 1) দেওয়া থাকবে। তার পরবর্তী লাইনে চারটি পূর্ণসংখ্যা rk, ck, rh এবং ch থাকবে। rk এবং ck হল কাইজির ব্লকের সারি ও কলাম নম্বর। rh এবং ch হল চেয়ারম্যান হৌদৌর ব্লকের সারি ও কলাম নম্বর।


Input

The first line of the input gives the number of test cases, T (1 <= T <= 30). T test cases follow. Each will consist of one line containing two integers M (number of rows) and N (number of columns), where 1 <= M, N <= 100. This is followed by M lines each containing N space-separated integers (each integer is either 0 or 1). The next line containing four integers rk, ck, rh and ch. rk and ck are the initial row and column of Kaiji’s cell; while, rh and ch are the initial row and column of Hyoudou’s cell.


অাউটপুটের বর্ণনা

প্রতিটি টেস্টকেসের জন্য একটি লাইনে একটি শব্দ W আউটপুট দিতে হবে। কাইজি জিতলে W হল “Kaiji” আর চেয়ারম্যান জিতলে W হল “Chairman”. W শব্দটি কোটেশন ছাড়া প্রিন্ট করতে হবে।


Output

For each test case, output one line containing a single word W, where W is “Kaiji” if Kaiji wins and “Chairman” if Hyoudou wins. The word must be printed without the quotation marks.


Sample

InputOutput
2 5 10 1 0 0 0 1 1 1 0 0 0 1 0 1 1 0 1 0 1 1 0 1 1 0 0 1 0 0 1 0 0 0 0 1 1 1 1 1 1 0 0 0 0 0 0 1 1 0 0 1 0 4 7 1 4 6 5 0 0 1 0 0 0 1 0 1 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 2 3 5 2Chairman Kaiji