class.h ======= #define CLASS_SIZE 100 struct student { char *last_name; int student_id; char grade; }; class.c ======= #include "class_info.h" int fail(struct student class[]) /* Count the failing grades. */ { int i, cnt = 0; for (i = 0; i < CLASS_SIZE; ++i) cnt += class[i].grade == 'F'; return cnt; } complex.h ========= struct complex { double re; /* real part */ double im; /* imag part */ }; typedef struct complex complex; complex.c ========= #include "complex.h" void add(complex *a, complex *b, complex *c) /* a = b + c */ { a -> re = b -> re + c -> re; a -> im = b -> im + c -> im; }