Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include"stdafx.h";
- #include <iostream>
- using namespace std;
- int main() {
- int i = 0, p = 0, neg = 0;
- int a;
- while (i < 20){
- cout << "vvedite chislo =";
- cin >> a;
- if (a > 0) p++;
- else if (a < 0) neg++;
- i++;
- }
- cout << "p: " << p << ", neg: " << neg << endl;
- system ("pause");
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement