C语言 include<stdbool.h> 中stdbool 是 什么意思

2025-03-02 02:27:00
推荐回答(1个)
回答1:

bool 是C++中的关键字,C中不支持
所以C99标准中引入了头文件 stdbool.h,包含了四个用于布尔型的预定义宏
#define true 1
#define false 0
#define bool _Bool
typdef int _Bool
看看 stdbool.h 的内容就知道了。