foo.cc: In function ‘int main()’:
foo.cc:7:12: warning: init-statement in selection statements only available with ‘-std=c++17’ or ‘-std=gnu++17’ [-Wc++17-extensions]
7 | if(x==1)cout<<"No"<<endl;
| ^
foo.cc:7:15: error: unable to find numeric literal operator ‘operator"")cout’
7 | if(x==1)cout<<"No"<<endl;
| ^~~~~~~
foo.cc:7:15: note: use ‘-fext-numeric-literals’ to enable more built-in suffixes
foo.cc:8:9: error: expected primary-expression before ‘else’
8 | else if(x==2) cout<<"Yes"<<endl;
| ^~~~
foo.cc:7:35: error: expected ‘)’ before ‘else’
7 | if(x==1)cout<<"No"<<endl;
| ~ ^
| )
8 | else if(x==2) cout<<"Yes"<<endl;
| ~~~~