C Program To Calculate Area Of Right Angle Triangle

C Program To Calculate Area Of Right Angle Triangle

#include<stdio.h>

int main()
{
   int base, height;
   float area;

   printf("Enter base of Right Angle Triangle : \n");
   scanf("%d", &base);  //input from user

   printf("Enter height of Right Angle Triangle :\n ");
   scanf("%d", &height);  //input from user

   area = 0.5 * base * height;   //Area Calculate
   printf("Area of Right Angle Triangle : %f\n", area);   //Print Output On screen

}

Related Posts