• Source
    1. #include<stdio.h>
    2. #include<math.h>
    3. int main()
    4. {
    5. long long int t,r,y,R;
    6. double a,b,c,d;
    7. scanf("%lld",&t);
    8. while(t--)
    9. {
    10. scanf("%lld%lld%lld",&r,&y,&R);
    11. a=(r*r)+(y*y);
    12. b=sqrt(a);
    13. c=R+b;
    14. d=R-b;
    15. printf("%.2lf %.2lf\n",d,c);
    16. }
    17. return 0;
    18. }