Sunday, March 20, 2016

URI 1116 - Dividing X by Y

#include<stdio.h>
main()
{
    double x, y ;
    long int T;
    scanf("%ld",&T);
    while(T--){
        scanf("%lf %lf",&x,&y);
        if(y==0)
            printf("divisao impossivel\n");
        else
            printf("%.1lf\n",x/y);
    }
}

No comments:

Post a Comment