Boolean function in Turbo C++

Jan 9, 2015 at 11:44am
Is the boolean function already defined under the default headers? Else, how would I create one?
Would this work? :
1
2
3
4
#define true 1
#define false 0
typedef int bool;
Bool x=true;
Jan 9, 2015 at 11:59am
Is the boolean function already defined under the default headers?
No, because it is part of the language itself, not the standard library.

Would this work? :
No, you are not allowed to redefine reserved keywords.

C++ already has builtin boolean type.
Jan 9, 2015 at 12:24pm
Could you tell me how would I call it in Turbo C++? Cause it doesn't seem to be working for me.
Jan 9, 2015 at 12:39pm
http://www.learncpp.com/cpp-tutorial/26-boolean-values/

I suggest to use proper compiler instead of TurboC++: it is full of obscure bugs, wasn't updated since previous century and does not follows standards.
Topic archived. No new replies allowed.