
C
w741627265
这个作者很懒,什么都没留下…
展开
-
C语言结构体初始化的几种方法
定义 struct main_widgets { int first; double second; float third; char * four; }; 方法一:定义时赋值 struct s_main_widgets test = {-10, 3.14,0.25,"main_widgets"}; 或者 struct s_main_widgets t...原创 2019-07-26 13:47:36 · 372 阅读 · 0 评论 -
实现自己的printf打印 -- 可变参数的函数
/*X86平台,参数传递是基于堆栈来完成的,对内存使用时连续的*/ void printf_myself(const char *format, ...) { //char *ptr_s = &format; int num; char ch; double d; struct _student stu; //const char *name_str; ...原创 2018-08-05 16:00:24 · 826 阅读 · 0 评论