構造体
例文4 関数に構造体を引数として渡す
#include <stdio.h> struct STUDENT{ char *name; int age; }; void func(struct STUDENT); int main(void){ struct STUDENT taro; taro.name = "TARO"; taro.age = 15; func(taro); return 0; } void func(struct STUDENT student){ printf("%s -- %d\n",student.name, student.age); }