Untitled
Anonymous
plain_text
10/18/2023 4:59 PM
416 B
22
Indexable
#include <iostream>
using namespace std;
int main()
{
int a, b , c;
a = 1;
b = 1;
c = 1;
setlocale(LC_ALL, "RUS");
cout << "Введите число >0 или придет конец" << endl;
while (a)
{
cin >> a;
if (a > 0) b *= a;
else a = 0;
}
cout << b << endl;
}Editor is loading...