C基础
「已注销」
这个作者很懒,什么都没留下…
展开
-
C_strlen&sizeof
关于 sizeof 和 strlen 各种情况1、strlen 只能计算字符串,使用strlen表示从当前位置出发 ,直到’\0’,计算中间字符的长度(即字符的数量),如果在字符中强行使用strlen,属于未定义行为(UB),2、sizeof两个都可以计算,sizeof...原创 2020-03-05 14:53:35 · 102 阅读 · 0 评论 -
detailed explanation of structure
Structure is also called record in some programming languages.Here is an example:struct Student{ int num; char name[20]; char sex; int age; float score; char addr[30]; // Address is a string}...原创 2019-12-15 16:08:12 · 158 阅读 · 0 评论 -
simple definition of structure
simple definition of structureEnum Sex{ MALE. FEMALE};//Student is the structure name, struct student is the structure type, and the contents are member variablesstruct Student{ char name[1024]...原创 2019-12-15 08:08:30 · 129 阅读 · 0 评论