Codedamn Sprint Showdown

Easy
5
2
19.7% Acceptance

In a thrilling 400-meter dash at the Codedamn Annual Sprint, three contenders, namely Alice, Bob, and Charlie, fiercely competed for the title. Each participant finished the race in distinct times: Alice in XX seconds, Bob in YY seconds, and Charlie in ZZ seconds. Your task is to determine who boasted the highest average velocity throughout the course.

Input Specifications

  • The initial line will present a single integer TT, indicating the total number of races analyzed.
  • Following this, each race is detailed over several lines:
    • For each race, the first line will list three integers separated by spaces, X,Y,X, Y, and ZZ. These represent the completion times of Alice, Bob, and Charlie, respectively.

Output Specifications

After evaluating each race, indicate who had the swiftest average pace by printing:

  • ALICE, if Alice demonstrated superior speed.
  • BOB, if Bob outpaced the others.
  • CHARLIE, if Charlie was the fastest.

Output can disregard case sensitivity, meaning ALICE, alice, or any variation thereof are equivalent.

Constraints

  • 1T10001 \leq T \leq 1000
  • 1X,Y,Z1001 \leq X, Y, Z \leq 100
  • It is guaranteed that X,Y,X, Y, and ZZ are distinct.

Sample Races and Analysis

Race #1:

Input:

3 1 2 8 4 100 1 7 3 5

Output:

ALICE CHARLIE BOB

Analysis

Race 11: In this instance, the time to complete the 400-metre dash was 1,2,1, 2, and 88 seconds for the contenders, respectively. Consequently, their speeds were 4001=400,4002=200,\frac{400}{1} = 400, \frac{400}{2} = 200, and 4008=50\frac{400}{8} = 50 meters per second, respectively.

Alice emerged as the speediest in this scenario.

Race 22: The racers concluded the dash in 4,100,4, 100, and 11 second(s) respectively, translating to speeds of 4004=100,400100=4,\frac{400}{4} = 100, \frac{400}{100} = 4, and 4001=400\frac{400}{1} = 400 meters per second respectively.

In this race, Charlie showcased unmatched speed.

Race 33: With Bob completing the race in the shortest time, he claimed the highest average velocity.