C99中的BOOL数据类型是什么 [英] What is BOOL datatype in C99
问题描述
ANSI C99中的BOOL数据类型是什么?我希望它与BOOLEAN有关。
我搜索了互联网,但最终没有使用的信息。
寻找BOOL的详细说明..... ...........
__________________________________________________ _______________
是否有基于ANSI C99的编译器可从互联网下载?
谢谢.........
让我知道你发现了什么。我以为BOOL是一个unsigned int的Microsoft typedef。你是测试它是真还是假,因为它可能包含0或1以外的数字。
FALSE是:
#define FALSE 0
和TRUE是:
#define TRUE!FALSE
让我知道你发现了什么。我以为BOOL是一个unsigned int的Microsoft typedef。你是测试它是真还是假,因为它可能包含0或1以外的数字。
FALSE是:
#define FALSE 0
和TRUE是:
#define TRUE!FALSE
我现在指的是这本书-------->
计算机基础知识和编程C
作者:PRADIP DEY和MANAS ghosh
OXFORD大学出版社
在本书的第205页,提到了 -
__________________________________________________ _______________
"可能的数据类型的完整列表如下:
bool(根据C99)
char
unsigned char
signed char
int
unsigned int
signed int
short int
unsigned short int
签名短int
long int
签名long int
unsigned long int
浮动
双倍
长双倍
__________________________________________________ _______________
我无法找到(可能)该书中的任何其他内容,因为它基于ANSI C89(可能)。
就是这样。我所知道的BOOL目前就是这个。欢迎任何有关此事的帮助.............
~~感谢~~
有BOOL和bool之间的区别。我的意思是,视觉差异。
在C ++中,bool是一个包含true或false的类型:
展开 | 选择 | Wrap | 行号
What is BOOL datatype in ANSI C99? I expect it to be related with BOOLEAN.
I searched internet for it but ended with information of no use.
Looking for an detailed description of BOOL................
__________________________________________________ _______________
Is there any ANSI C99 based compiler for download from internet?
THANKS.........解决方案Let me know what you find out. I thought BOOL was a Microsoft typedef of an unsigned int. You were you test it a TRUE or FALSE since it could contain numbers other than 0 or 1.
FALSE is:
#define FALSE 0
and TRUE is:
#define TRUE !FALSE
Let me know what you find out. I thought BOOL was a Microsoft typedef of an unsigned int. You were you test it a TRUE or FALSE since it could contain numbers other than 0 or 1.
FALSE is:
#define FALSE 0
and TRUE is:
#define TRUE !FALSEI''m presently referring to the book-------->
Computer Fundamentals and Programming in C
By : PRADIP DEY and MANAS ghosh
OXFORD university press
In this book, on page-205 , it is mentioned that-
__________________________________________________ _______________
"A complete list of possible data types is as:
bool (according to C99)
char
unsigned char
signed char
int
unsigned int
signed int
short int
unsigned short int
signed short int
long int
signed long int
unsigned long int
float
double
long double
__________________________________________________ _______________
I couldnot find (probably) anything else about it in that book as it is based on ANSI C89 (probably).
That''s it. All that I know about BOOL presently is this. Any help in this matter is welcomed.............
~~THANKS~~
There is a difference between BOOL and bool. I mean, a visual difference.
In C++ bool is a type that contains true or false:
Expand|Select|Wrap|Line Numbers
这篇关于C99中的BOOL数据类型是什么的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文