Problem: You are storing an integer array of length m in a database. To maintain internal integrity and protect data, the database stores n copies of this array.

Unfortunately, the recent incident may have altered the stored information in every copy in the database.

It's believed, that the incident altered at most two elements in every copy. You need to recover the original array based on the current state of the database.

In case there are multiple ways to restore the array, report any. If there is no array that differs from every copy in no more than two positions, report that as well.

Input

The first line contains integers n and m (2 ≤ n; 1 ≤ m; n ⋅ m ≤ 250 000) — the number of copies and the size of the array.

Each of the following n lines describes one of the currently stored copies in the database, it consists of m integers s_{i, 1}, s_{i, 2}, ..., s_{i, m} (1 ≤ s_{i, j} ≤ 10^9).

Output

If there is an array consistent with all given copies, print "Yes" and then the array itself. The array must have length m and contain integers between 1 and 10^9 only.

Otherwise, print "No".

If there are multiple possible arrays, print any of them.

Examples

Input


3 4
1 10 10 100
1 1 1 100
10 100 1 100


Output


Yes
1 10 1 100


Input


10 7
1 1 1 1 1 1 1
1 1 1 1 1 1 2
1 1 1 1 1 2 2
1 1 1 1 2 2 1
1 1 1 2 2 1 1
1 1 2 2 1 1 1
1 2 2 1 1 1 1
2 2 1 1 1 1 1
2 1 1 1 1 1 1
1 1 1 1 1 1 1


Output


Yes
1 1 1 1 1 1 1


Input


2 5
2 2 1 1 1
1 1 2 2 2


Output


No

Note

In the first example, the array [1, 10, 1, 100] differs from first and second copies in just one position, and from the third copy in two positions.

In the second example, array [1, 1, 1, 1, 1, 1, 1] is the same as the first copy and differs from all other copies in at most two positions.

In the third example, there is no array differing in at most two positions from every database's copy.

Solution (in CPP):

Solution:
#include <cstdio>
#include <cstring>
#include <vector>
#include <iostream>
#include <algorithm>
using namespace std;
#define pb push_back

const int N = 250020;

int n, m;
vector <int> v[N];

void print(){
	cout << "Yes" << endl;
	for(int i = 0;i < m;i ++) 
		cout << v[0][i] << " ";
	cout << endl;
}

int check(){
	for(int i = 1;i < n;i ++) {
		int num = 0;
		for(int j = 0;j < m;j ++) {
			if(v[0][j] != v[i][j]) 
				num ++;
		}
		if(num >= 3) return 0;
	}
	print();
	return 1;
}

bool work(int y){
    int st = 0,save;
    for(int i = 1;i < n;i ++){
        int k = 0;
        for(int j = 0;j < m;j ++){
            if(!st && j == y) continue;
            if(v[i][j] != v[0][j]) k ++;
        }
        if(k >= 3){
            if(st) v[0][y] = save;
            return 0;
        }
        if(k==2&&!st){
            save = v[0][y];
            v[0][y] = v[i][y];
            st = 1;
        }
    }
    print();
    return 1;
}

int main(){
	int x;
	scanf("%d%d", &n, &m);
	for(int i = 0;i < n;i ++) {
		for(int j = 0;j < m;j ++) {
			scanf("%d",&x);
			v[i].pb(x);
		}
	}
	int t, st = 0, yes = 1;
	for(int i = 1;i < n;i ++) {
		int num = 0;
		for(int j = 0;j < m;j ++) {
			if(v[0][j] != v[i][j]) 
				num ++;
		}
		if(num > 4) {
			cout << "No" << endl;
			return 0;
		}
		if(num == 3 && st == 0) {
			t = i;
			yes = 0;
		}
		if(num == 4) {
			t = i;
			st = 1;
			yes = 0;
		}
	}

	if(yes == 1){
		print();
		return 0;
	}

	vector <int> z;
	for(int i = 0;i < m;i ++) 
		if(v[0][i] != v[t][i])
			z.pb(i);
	
	if(st == 0){ // 3
		for(int i = 0;i < z.size();i ++) {
			int save1 = v[0][z[i]];
			v[0][z[i]] = v[t][z[i]];
			if(check()) return 0;
			for(int j = 0;j < m;j ++) {
				if(z[i] == j) continue;
				if(work(j)) return 0;        //!
			}
			v[0][z[i]] = save1;
		}
	}
	else{ // 4		
		for(int i = 0;i < z.size();i ++) {
			int save1 = v[0][z[i]];
			v[0][z[i]] = v[t][z[i]];
			for(int j = i + 1;j < z.size();j ++) {
				int save2 = v[0][z[j]];
				v[0][z[j]] = v[t][z[j]];
				if(check()) return 0;
				v[0][z[j]] = save2;
			}
			v[0][z[i]] = save1;
		}
	}
	cout << "No" << endl;
	return 0;
}
/*
9 9
1 2 2 2 2 1 2 2 2
1 2 2 1 1 2 2 2 1
1 2 2 1 2 2 2 2 1
1 2 2 1 2 2 1 2 1
1 2 2 1 2 2 1 2 1
1 2 2 1 2 2 2 2 1
1 2 2 2 1 1 2 2 1
1 2 2 2 1 1 2 2 1
1 2 1 2 2 2 2 2 1

Yes
1 2 2 2 2 2 2 2 1

5 5
1  2  3  4  5
6 11  3  4  7
1  8  3 12 16
1 13  3  4 17
1  8 14  4 15

Yes
1  8  3  4  7

4 6
1 1 1 1 1 1
2 2 2 1 1 1
1 1 3 1 1 2
1 4 3 1 2 1

No
*/