Hdu 4969 Just a Joke (points)

Source: Internet
Author: User

Hdu 4969 Just a Joke (points)

Link: hdu 4969 Just a Joke

Guizeyanhua is going to chase a girl. The girl is moving at a uniform speed on the Circle centered around Guizeyanhua and with a radius of R. The girl's speed is v1, The Guizeyanhua speed is v2, and the radius is R, guizeyanhua can only run from D to leg pain. Now, Guizeyanhua is going to chase girls only if they are girls and Guizeyanhua are in the same circle.

Solution: Because there are three conditions that need to be collocated, Guizeyanhua and girls must have the same line speed, so v1R = vxr (vx is the speed of Guizeyanhua In the tangent of the circle ), because the speed of Guizeyanhua is determined to be v2, there are v22 = v2x + v2y (vx is the speed of Guizeyanhua approaching the girl's direction), and there are both vy = v22? R2v21R2, and vy = drdt, so dt = 1 vydr. Points r to find out how long it takes for Guizeyanhua to catch up with the girl. Then, use the time t to multiply v2, that is, the distance Guizeyanhua traveled.
The integral part is replaced by a triangle. The original function is y = arcsin (Rrv1)

#include 
  
   #include 
   
    #include 
    
     #include using namespace std;int main () {    int cas;    double v1, v2, r, d;    scanf("%d", &cas);    while (cas--) {        scanf("%lf%lf%lf%lf", &v1, &v2, &r, &d);        double t = r / v1 * asin(v1 / v2);        double l = t * v2;        printf("%s\n", l > d ? "Why give up treatment" : "Wake up to code");    }    return 0;}
    
   
  

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.