top button
Flag Notify
    Connect to us
      Facebook Login
      Site Registration

Facebook Login
Site Registration

C Program to Calculate Area of Right angle Triangle?

+2 votes
73 views
C Program to Calculate Area of Right angle Triangle?
posted Dec 2, 2014 by Manikandan J

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

1 Answer

+2 votes
 
Best answer
#include<stdio.h>

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

   printf("\nEnter the base of Right Angle Triangle : ");
   scanf("%d", &base);

   printf("\nEnter the height of Right Angle Triangle : ");
   scanf("%d", &height);

   area = 0.5 * base * height;
   printf("\nArea of Right Angle Triangle : %f", area);

   return (0);
}

Output :

Enter the base of Right Angle Triangle   : 4
Enter the height of Right Angle Triangle : 8
Area of Right Angle Triangle : 16.0
answer Dec 2, 2014 by Shivaranjini
Contact Us
+91 9880187415
sales@queryhome.net
support@queryhome.net
#280, 3rd floor, 5th Main
6th Sector, HSR Layout
Bangalore-560102
Karnataka INDIA.
QUERY HOME
...