Long long ago, there is an ant crawling on an L-meter magic rubber band with speed of v cm/s.The magic rubber band will elongate m meters every second. We can assume that the magic rubber band elongates equably. Now, the ant is on the start point and crawling to another point, please tell me whether it can reach the endpoint.
The first line of the input is T, which stands for the number of test cases you need to solve.
Each case include three integers: L , v , m ( 0< L< 10^9,0<= v, m< 10^ 9,).
For each test case, if the ant can reach endpoint, output "YES", otherwise "NO".
1
99999 61 1
Sample Output
YES
#include<stdio.h>
int main()
{
int t,l,v,m;
scanf("%d",&t);
while(t--)
{
scanf("%d%d%d",&l,&v,&m);
if (v>0)
printf("YES\n");
else
printf("NO\n");
}
return 0;
}
本文介绍了一个有趣的数学问题:一只蚂蚁以固定速度在一根能够均匀伸长的魔法橡皮筋上爬行,探讨了蚂蚁能否到达终点的可能性。输入包括测试案例的数量及每例中的橡皮筋初始长度、蚂蚁速度和橡皮筋每秒伸长量。

980

被折叠的 条评论
为什么被折叠?



