fork download
  1. #include <iostream>
  2.  
  3. struct foo {
  4. bool a = true;
  5. bool b = false;
  6. bool c;
  7. };
  8.  
  9. foo bar{.a = false, .c=true};
  10.  
  11. int main()
  12. {
  13. std::cout << bar.a << " "<< bar.b << " "<< bar.c << std::endl;
  14. return 0;
  15. }
Success #stdin #stdout 0.01s 5276KB
stdin
Standard input is empty
stdout
0 0 1