Skip to content

Instantly share code, notes, and snippets.

@orontee
Created September 25, 2013 09:12
Show Gist options
  • Save orontee/6697050 to your computer and use it in GitHub Desktop.
Save orontee/6697050 to your computer and use it in GitHub Desktop.
#include <iostream>
int main()
{
const bool true_val();
const bool val;
bool *const ptr();
bool *const other_ptr;
std::cout << "Default initialization: " << true_val << '\n'
<< "Uninitialized" << val << '\n'
<< "Default initialization (pointer): " << ptr << '\n'
<< "Uninitialized (pointer): " << other_ptr << '\n';
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment