#include <stdio.h>

int main() {
    int height[10];
    for(int i=0; i<10; i++){
        scanf("%d", &height[i]);
    }

    //평균
    int sum=0;
    for(int i=0;i<10;i++){
        sum += height[i];
    }
    printf("평균: %d\n", sum/10);

    //제일 큰 값 구하기
    int max;
    for(int i=0;i<10;i++){
        if(height[i] > max){
            max = height[i];
        }
    }
    printf("제일 큰 키: %d\n", max);

    //제일 작은 값 구하기
    int min = height[0];
    for(int i=0;i<10;i++){
        if(min > height[i]){
            min = height[i];
        }
    }
    printf("제일 작은 키: %d\n", min);
    
}

Embed on website

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