Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- /*
- A Program Using Boolean Variables
- */
- int main()
- {
- //Creates Boolean Variable
- bool BoolValue;
- //Sets Boolean Variable to true then displays output "1" for true
- BoolValue = true;
- cout << BoolValue << endl;
- //Sets Boolean Variable to false then displays output "0" for false
- BoolValue = false;
- cout << BoolValue << endl;
- //Returns 0 to machine (end of code)
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement