SP9340 ARBITRAG - Arbitrage
Description
Arbitrage is the use of discrepancies in currency exchange rates to transform one unit of a currency into more than one unit of the same currency. For example, suppose that 1 US Dollar buys 0.5 British pounds, 1 British pound buys 10.0 French francs, and 1 French franc buys 0.21 US dollars. Then, by converting currencies, a clever trader can start with 1 US dollar and buy 0.5 \* 10.0 \* 0.21 = 1.05 US dollars, making a profit of 5 percent.
Your job is to write a program that takes a list of currency exchange rates as input and then determines whether arbitrage is possible or not.
Input Format
The input file will contain one or more test cases. On the first line of each test case there is an integer _n_ (1
Output Format
For each test case, print one line telling whether arbitrage is possible or not in the format "Case _case_: Yes", respectively "Case _case_: No".