2023年12月19日

C语言 不定长数组

摘要: #include <stdio.h> #include <malloc.h> struct student { int age; }; struct data { int len; // 不占用空间 struct student students[0]; }; int main() { struct 阅读全文

posted @ 2023-12-19 21:15 王景迁 阅读(64) 评论(0) 推荐(0) 编辑

C语言 函数数组

摘要: #include <stdio.h> // float代表函数返回值 // my_func_name代表函数地址 // int代表函数参数 typedef float (*my_func_name)(int); float a(int i) { return 1.0 + i; } float b(i 阅读全文

posted @ 2023-12-19 20:42 王景迁 阅读(7) 评论(0) 推荐(0) 编辑

导航