bool [C++ Reference]
Keywords: keywords,bool
Date: 2008-10-14T15:42:04-0700

## bool

The keyword bool is used to declare Boolean logic variables; that is, variables which can be either true or false. For example, the following code declares a boolean variable called done, initializes it to false, and then loops until that variable is set to true.

         bool done = false;
         while( !done ) {
         ...
         }

Also see the data types page.

Related Topics: char, double, false, float, int, long, short, signed, true, unsigned, wchar_t