Fix Lesson 1 Task 3

This commit is contained in:
Stanislav Mykhailenko 2024-06-12 11:30:25 +03:00
parent 0ae4eb5552
commit 98eb242ee3
GPG key ID: 1E95E66A9C9D6A36

View file

@ -10,11 +10,23 @@ int main()
if (money < 1000) if (money < 1000)
cout << "Work more. "; cout << "Work more. ";
if (money > 999)
if (money < 1001) {
cout << "Illegal salary." << endl;
return 1;
}
if (money > 1000) { if (money > 1000) {
if (money > 1000000) if (money > 1000000)
cout << "You are a millionaire. "; cout << "You are a millionaire. ";
if (money < 1000000) if (money < 1000000)
cout << "You work great. "; cout << "You work great. ";
if (money > 999999)
if (money < 1000001) {
cout << "Illegal salary." << endl;
return 1;
}
} }
cout << "You are doing great!" << endl; cout << "You are doing great!" << endl;