C++ printing boolean, what is displayed?
The standard streams have a boolalpha flag that determines what gets displayed — when it’s false, they’ll display as 0 and 1. When it’s true, they’ll display as false and true. There’s also an std::boolalpha manipulator to set the flag, so this: …produces output like: For what it’s worth, the actual word produced when boolalpha is set to true is localized–that is, <locale> has a num_put category that handles numeric conversions, …