Answers for "area of trapezoid in c program"

1

c trapezoid area

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

int main() {
	double a, b, c, d;
	
	printf("TRAPEZOID AREAnnnMajor base: ");
	scanf("%lf", &a);
	
	printf("nMinor base: ");
	scanf("%lf", &b);
	
	printf("nHeight: ");
	scanf("%lf", &c);
	
	d = (a + b)*c/2.0;
	
	printf("nnThe area is: %lfnnn", d);
	
	
	system("pause");
}
Posted by: Guest on February-11-2021

Code answers related to "area of trapezoid in c program"

Browse Popular Code Answers by Language