#include <stdio.h>

typedef struct {
    int id;
    int weight;
    int height;
} Body;

// swap関数: Body型の2つの変数を入れ替える
void swap(Body *a, Body *b) {
    Body w = *a;
    *a = *b;
    *b = w;
}

int main() {
    Body a[] = {
        {1, 65, 169},
        {2, 73, 170},
        {3, 59, 161},
        {4, 79, 175},
        {5, 55, 168}
    };
    int n = sizeof(a) / sizeof(a[0]);

    // 身長を基準に降順にソート
    for (int i = 0; i < n - 1; i++) {
        for (int j = 0; j < n - i - 1; j++) {
            if (a[j].height < a[j + 1].height) {
                swap(&a[j], &a[j + 1]);
            }
        }
    }

    // 結果の表示
    printf("ID\tWeight\tHeight\n");
    for (int i = 0; i < n; i++) {
        printf("%d\t%d\t%d\n", a[i].id, a[i].weight, a[i].height);
    }

    return 0;
}