+ 1
A little problem.
When you enter " 1 " you can see immediately 2 answers. How to fix it? https://code.sololearn.com/cWfefDYe1CWf/?ref=app
2 Réponses
+ 5
#include <iostream>
using namespace std;
int main()
{
int a;
cout<< "Hi. Please, choose right answer. \n \n \n";
cout<< "1. The formula of water?" <<endl <<endl;
cout<< "1 - H2O 2 - HCl" <<endl <<endl <<endl <<endl;
cin>>a;
if (a == 1) { cout<< "Right!"; }
else if (a == 2) { cout<< "Not right!"; }
else { cout<< "Here is only 2 answers."; }
return 0;
}
+ 1
hai i do it https://code.sololearn.com/cIxz3zXXtNz2