重要的其他

1.long long int(简写:long long),C99 标准添加的类型,有符号整数

  第一次移植雷神demo出错时,是C标准不同。

2.数值常数后缀不区分字母大小写。

0UL表示无符号长整bai型0,1UL表示无符号du长整型1。如果不写UL后缀,系统默zhi认为:int, 即,有符号整数。

3.作收藏的stdint.h文件

typedef signed char        int8_t;
typedef short              int16_t;
typedef int                int32_t;
typedef long long          int64_t;
typedef unsigned char      uint8_t;
typedef unsigned short     uint16_t;
typedef unsigned int       uint32_t;
typedef unsigned long long uint64_t;    

 

 

4.代码规范收集

尽量避免使用浮点数,如pid的场合

 

posted @ 2020-07-15 23:16  前方路wx  阅读(126)  评论(0编辑  收藏  举报