uri online judge problem 1012 solution c programming

   UIR online judge problem 1012 solution c             programming

   PROGRAM CODE  :

   sample input  :  3.0   4.0    5.2



#include<stdio.h>
#include<math.h>
int main()
{
    double A,B,C,RETAN,pi,CIRC,tr,TRIA,QU;
    scanf("%lf %lf %lf",&A,&B,&C);
    pi=3.14159;

    TRIA=.5*A*C;
    CIRC= pi * pow(C, 2);
    tr=(A+B)/2*C;
    QU=B*B;
    RETAN=A*B;



    printf("TRIANGULO: %.3lf\n",TRIA);
    printf("CIRCULO: %.3lf\n",CIRC);
    printf("TRAPEZIO: %.3lf\n",tr);
    printf("QUADRADO: %.3lf\n",QU);
    printf("RETANGULO: %.3lf\n",RETAN);
    return 0;
}



OUTPUT :





No comments

Powered by Blogger.