stdbool, c语言的标准函数库中的头文件stdbool, h在c99中引入, 包含四个用于布尔型的预定义宏, ieee, 1003, 2001标准中的宏定义包括, bool, 会扩展为, bool, true, 会扩展为1, false, 会扩展为0, bool, true, false, defined, 会扩展为1如下例所示, include, stdio, include, stdlib, include, stdbool, main, void, bool, keep, going, true, 也可. C语言的标准函数库中的头文件stdbool h在C99中引入 包含四个用于布尔型的预定义宏 IEEE 1003 1 2001标准中的宏定义包括 b bool b 会扩展为 Bool b true b 会扩展为1 b false b 会扩展为0 b bool true false are defined b 会扩展为1如下例所示 include lt stdio h gt include lt stdlib h gt include lt stdbool h gt int main void bool keep going true 也可以是 bool keep going 1 while keep going printf 本程序会在keep going为真时持续运行 n keep going false 也可以是 keep going 0 printf 停止运行 n return EXIT SUCCESS 该程序会输出 本程序会在keep going为真时持续运行 停止运行 外部链接 编辑stdbool h 布尔类型及其值 基本定义 Base Definitions 参考 单一UNIX 规范第7期 由國際開放標準組織发布 取自 https zh wikipedia org w index php title Stdbool h amp oldid 60464387, 维基百科,wiki,书籍,书籍,图书馆,