#t492. 鸡尾酒疗法

鸡尾酒疗法

Cocktail Therapy

Problem Description

"Cocktail therapy" originally refers to "Highly Active Antiretroviral Therapy" (HAART), proposed in 1996 by Chinese-American scientist David Ho. It treats AIDS by combining three or more antiviral drugs. This approach reduces drug resistance from single-drug use, maximises suppression of viral replication, and partially or fully restores compromised immune function — thereby slowing disease progression, extending patients' lives, and improving quality of life. Building on cocktail therapy, many improved therapies have been proposed. To verify whether an improved therapy works better than cocktail therapy, a clinical controlled trial can be used.

Suppose cocktail therapy has an efficacy rate xx and a new therapy has efficacy rate yy. If y−x>5%y - x > 5\%, the new therapy is better; if x−y>5%x - y > 5\%, it is worse; otherwise their effects are about the same.

Below are nn groups of clinical controlled trials. The first group uses cocktail therapy, and the other n−1n - 1 groups are various improved therapies. Write a program to judge the effect of each improved therapy.

Input Format

The first line is an integer nn (1<n≤201 < n \le 20).

The remaining nn lines each contain two integers: the first is the total number of cases in the clinical trial (at most 1000010000), the second is the number of cases where the therapy was effective.

Among these nn lines, the first line is the cocktail-therapy data and the rest are the improved-therapy data.

Output Format

There are n−1n - 1 lines of output, each showing the effect of the corresponding improved therapy:

  • If it is better, output better.
  • If it is worse, output worse.
  • Otherwise output same.

These words must be printed exactly as shown — the judge compares them character by character.

Sample Input

5
125 99
112 89
145 99
99 97
123 98

Sample Output

same
worse
better
same

Constraints

1<n≤201 < n \le 20; cases per trial ≤10000\le 10000.

Hint

  • For each improved therapy compute its efficacy rate yy and compare y−xy - x with 5%5\% (use the total-case counts as the denominator).