1#include<bits/stdc++.h>
2using namespace std;
3
4int main(){
5
6 int q;
7
8 cin >> q;
9 for(int i = 0; i < q; i++){
10 int a,b,c;
11 cin >> a >> b >> c;
12 abs(a-c) < abs(b-c) ? cout << "Cat A" : abs(b-c) < abs(a-c) ? cout << "Cat B" : cout << "Mouse C";
13 cout << endl;
14 }
15 return 0;
16}