727div.2补题
A. Contest Start
There are n people participating in some contest, they start participating in x minutes intervals. That means the first participant starts at time 0, the second participant starts at time x, the third — at time 2⋅ x, and so on.
Duration of contest is t minutes for each participant, so the first participant finishes the contest at time t, the second — at time t+x, and so on. When a participant finishes the contest, their dissatisfaction equals to the number of participants that started the contest (or starting it now), but haven’t yet finished it.
Determine the sum of dissatisfaction of all participants.
Input
The first line contains a single integer k (1≤k≤1000) — the number of test cases.
Each of the next k lines contains three integers n, x, t (1≤n,x,t≤2⋅109) — the number of participants, the start interval and the contest duration.
Output
Print k lines, in the i-th line print the total dissatisfaction of participants in the i-th test case.
Example
4
4 2 5
3 1 2
3 3 10
2000000000 1 2000000000
5
3
3
1999999999000000000
题意:
有n个人参加比赛,第一个人参赛时间是0,第二个人参赛时间是x,第三个人参赛时间是x2,以此类推。。。
每个人的表演时间是t,第一个人在 t 时刻表演结束,第二个人在 t+x 时刻表演结束,第三个人在第 t+x2 时刻表演结束,以此类推。。。
每个人都有自己的不满意度,他的不满意度是他结束时正在表演的人数。注意&#x