Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main()
- {
- int a[5][5];
- for (int i = 0; i <3; i++)
- for (int j = 0; j <3; j++)
- cin >> a[i][j];
- cout << endl;
- bool b, q;
- b = false;
- for (int i = 0; i < 3 && !b; i++)
- {
- q = true;
- for (int j = 0; j < 3 && q; j++)
- for (int k = 0; k < 3; k++)
- {
- if (a[i][k] != 0)
- q = false;
- b = q;
- }
- }
- for (int i = 0; i < 3; i++)
- {
- for (int j = 0; j < 3; j++)
- cout << a[i][j];
- cout << endl;
- }
- if (b) cout << "YEs";
- else cout << "Stupid boy";
- system("pause");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment