Odpowiedź:
int main() {
int counter = 0, temp, wyn = 0;
do {
cin >> temp;
if (temp < 0) {
wyn++;
}
counter++;
} while (counter < 10);
cout << "nieujemnych: " << 10 - wyn << endl
<< "ujemnych : " << wyn << endl;
Wyjaśnienie:
" Life is not a problem to be solved but a reality to be experienced! "
© Copyright 2013 - 2024 KUDO.TIPS - All rights reserved.
Odpowiedź:
int main() {
int counter = 0, temp, wyn = 0;
do {
cin >> temp;
if (temp < 0) {
wyn++;
}
counter++;
} while (counter < 10);
cout << "nieujemnych: " << 10 - wyn << endl
<< "ujemnych : " << wyn << endl;
}
Wyjaśnienie: