Если я ввожу "fine" или "bad" он пишет оба условия (и fine, и bad). С остальным вроде разобралась. #include ;
using namespace std;
int main()
{
string name;
cout << "What is your name? ";
cin >> name;
cout << "Hello, " << name << endl;
cout << "How are you? ";
string Good;
string Fine;
string Bad;
string mood;
cin >> mood;
if (mood == "Good"||"good") {
cout << "Okay, so do you mind to play with me? ";
}
if (mood == "Fine"||"fine") {
cout << "I don't wanna annoy you but do you mind playing with me? ";
}
if (mood == "Bad"||"bad") {
cout << "Oh, what happened? Can I help you? Do you mind playing with me? It's really fun. You'll like it";
}
return 0;
}
Please enter comments
Please enter your name.
Please enter the correct email address.
You must agree before submitting.

Answers & Comments


Copyright © 2024 SCHOLAR.TIPS - All rights reserved.