Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main() {
- int n,m,i,j,a[100][100],x,y,ok=1;
- cout<<"n=";cin>>n;
- cout<<"m=";cin>>m;
- for (i=0;i<n;i++)
- for (j=0;j<m;j++)
- cin>>a[i][j];
- cout<<"x=";cin>>x;
- cout<<"y=";cin>>y;
- for (i=0;i<m&&ok;i++)
- {
- if (a[x][i]!=a[y][i])
- ok=0;
- }
- if (ok)
- cout<<"DA";
- else
- cout<<"NU";
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement