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

int main()
{
	float x=1, a=1, b, c, d, e, f, a1=1, b1, c1, d1, e1, f1;
	
	
	printf("\nInforme Altura %0.f:", a);
	scanf("%f",&b);
	c+=b;
	e=b;
    f=b;
	do
	{
		a++;
	    printf("\nInforme Altura %0.f:",a);
	    scanf("%f",&b);
	    
	    c+=b;
		
		if(b > e && b != 0)
		{
			e=b;
		}
		else if(b < f && b != 0)
		{
			f=b;
		}
    }
    while(b != 0);
    d=c/(a-1);
    printf("A media das alturas foi:%f",d);
    printf("\nA maior Altura e:%f",e);
    printf("\nA menor Altura e:%f",f);
    
    printf("\n\n\n\n\n\nInforme peso %0.f:", a1);
	scanf("%f",&b1);
	c1+=b1;
	e1=b1;
    f1=b1;
	do
	{
		a1++;
	    printf("\nInforme peso %0.f:",a1);
	    scanf("%f",&b1);
	    
	    c1+=b1;
		
		if(b1 > e1 && b1 != 0)
		{
			e1=b1;
		}
		else if(b1 < f1 && b1 != 0)
		{
			f1=b1;
		}
    }
    while(b1 != 0);
    d1=c1/(a1-1);
    printf("O media das pesos foi:%f",d1);
    printf("\nO maior peso e:%f",e1);
    printf("\nO menor peso e:%f",f1);
    
}

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: