fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. c) if (gender == 1) cout <<"Wood"<<endl; else; cout<<"Redwood"<<endl;
  6. return 0;
  7. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cpp: In function ‘int main()’:
prog.cpp:5:1: error: ‘c’ was not declared in this scope
 c) if (gender == 1) cout <<"Wood"<<endl; else; cout<<"Redwood"<<endl;
 ^
prog.cpp:5:42: error: ‘else’ without a previous ‘if’
 c) if (gender == 1) cout <<"Wood"<<endl; else; cout<<"Redwood"<<endl;
                                          ^~~~
stdout
Standard output is empty