The Fancy Tavern
InterviewTime limit1sMemory limit128 MB
Two cards hit each other simultaneously until at least one dies; decide which card survives.
- Level
Easy3 of 10
- Topics
- Simulation, Math
- Solved
- No attempts yet
Problem
"Luckystone" is a card duel game, and Changsik plays it often.
Each card has an attack value and a life value printed on it. The left number is the attack value and the right number is the life value.
The two players each play one card, and the cards are compared by these rules.
- Both cards reduce the opponent card's life by their own attack value at the same time. Lost life is never restored.
- A card whose life drops to 0 or below dies.
- If both cards are still alive, the comparison continues.
Changsik has been losing lately, so he wants to work out the result before the duel starts.
Given the attack and life values of the two cards, write a program that prints whose card survives.
Input
The first line contains the attack value and the life value of the card played by player A, separated by a space.
The second line contains the attack value and the life value of the card played by player B in the same format.
Every attack value and life value is a natural number not greater than 100,000.
Output
Print PLAYER A if player A's card survives, or PLAYER B if player B's card survives.
Print DRAW if both cards die.
Do not print the quotation marks.