Question:C program for area of equilateral triangle 

Answer 
#include<stdio.h>
#include<math.h>

int main(){

    float a;
    float area;

    printf("Enter size of side of the equilateral triangle : ");
    scanf("%f",&a);

    area = sqrt(3)/4*(a*a);

    printf("Area of equilateral triangle is: %.3f",area);

    return 0;
}
Sample output: Enter size of side of the equilateral triangle: 5 Area of equilateral triangle is: 10.825 

+ ExplanationNot Moderated
+ Report
Total Preview: 545
C program for area of equilateral triangle
Copyright © 2024. Powered by Intellect Software Ltd