Problem Statement:
iPhone 6 was released a few days ago. It has 4.7 inches touch screen, 1 GB RAM, NFC, 8 MP camera, dual core CPU and of course iOS 8. It costs 6666 EGP, which is a huge price, given that these specifications were released in Android phones years ago. But Apple fans do not care, and want to buy it even if they can not afford it. The famous Saad Nabiha is no exception!

As a fan of Apple products, Saad owns almost all of them (Mac, iPad, iPod, ...). This has put a lot of strain on Saad's budget, and he will have to ask his parents again to lend him some money. Since Saad asked them for a lot of money last year (to buy iPhone 5S), only one of them will have enough money this time. Saad has exactly S EGP, his father has F EGP, and his mother has M EGP. Saad will ask only one of them for the minimum amount of money he needs (in addition to his money) to buy the phone. Tell us whether he will ask his father or mother?

Input Format:
Your program will be tested on one or more test cases. The first line of the input will be a single integer T, the number of test cases (1  ≤  T  ≤  100,000). Followed by T test cases. Each test case will consist of a single line, containing 3 integers separated by a single space: S, F, M (0  ≤  S, F, M  ≤  104) representing Saad's money, his father's money, and his mother's money, respectively.

Output Format:
For each test case print a single line containing "Case n:" (without the quotes) where n is the test case number (starting from 1) followed by a single space, followed by "dad" if he will ask his father for the money or "mom" if he will ask his mother for the money. It is guaranteed that exactly one solution will exist.

Sample Input:
2 200 1234 6543 200 6543 1234

Sample Output:
Case 1: mom Case 2: dad

Added by: ahmed_aly
Added at: 2014-10-11 15:00:00 UTC
Time Limit: 3 seconds
Partial score: No
Source:ACM Egyptian Collegiate Programming Contest 2014