Dunno#3933

Dunno

1 second
256 megabytes
Easy

Neznayka and his friends embarked on a space adventure, having built a new spaceship. Despite its advanced technology, the spaceship has a significant limitation. After flying for T_1 hours, the batteries must be recharged using solar panels for T_2 hours. During this recharging period, the spaceship's engine shuts down, causing it to drift backward. In T_1 hours of flight, the spaceship covers S_1 km, but during the T_2 hours of recharging, it moves back S_2 km. Your task is to calculate the time required for Neznayka and his friends to reach various planets, given the distance to each planet.

Input

The first line of the input contains , the number of test cases. Each of the following lines contains five natural numbers separated by spaces: T_1, T_2, S_1, S_2, (1 \le T_1, T_2, S_1, S_2, S \le 10000000).

Output

For each test case, output the time in hours (rounded to two decimal places) on a separate line, indicating how long it will take the spaceship to reach the planet. If reaching the planet is impossible with the given spaceship, output the word "NO" in uppercase Latin letters on a separate line.

Examples

Example 1

Loading
Loading