admin 管理员组

文章数量: 1086866

Codeforces Round #364 (Div. 1) A B C D E


E题好艰难。

唉,补完去搞midterm了。

A. As Fast As Possible time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output

On vacations n pupils decided to go on excursion and gather all together. They need to overcome the path with the length l meters. Each of the pupils will go with the speed equal to v1. To get to the excursion quickly, it was decided to rent a bus, which has seats for k people (it means that it can't fit more than kpeople at the same time) and the speed equal to v2. In order to avoid seasick, each of the pupils want to get into the bus no more than once.

Determine the minimum time required for all n pupils to reach the place of excursion. Consider that the embarkation and disembarkation of passengers, as well as the reversal of the bus, take place immediately and this time can be neglected.

Input

The first line of the input contains five positive integers nlv1, v2 and k (1 ≤ n ≤ 10 000, 1 ≤ l ≤ 109, 1 ≤ v1 < v2 ≤ 10

本文标签: Codeforces Round 364 (Div 1) A B C D E