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 <bits/stdc++.h>

using namespace std;

typedef long long ll;
typedef pair<int, int> pi;

pi operator - (pi a, pi b) { return { a.first - b.first, a.second - b.second }; }
pi operator + (pi a, pi b) { return { a.first + b.first, a.second + b.second }; }
ll operator * (pi a, pi b) { return a.first * 1LL * b.first + a.second * 1LL * b.second; }

const int dy[4] = { -1, 0, 1, 0 }, dx[4] = { 0, 1, 0, -1 };

int n, m;
vector<int> arr[250000];
vector<int> diff[250000];

bool chk() {
	for (int i = 0; i < n; ++i) {
		int cnt = 0;
		for (int j = 0; j < m; ++j)
			if (arr[0][j] != arr[i][j])
				cnt++;
		if (cnt > 2)
			return false;
	}
	return true;
}

int main() {
	ios_base::sync_with_stdio(false);
	cin.tie(nullptr);

	cin >> n >> m;
	int w = 0;
	for (int i = 0; i < n; ++i) {
		for (int j = 0; j < m; ++j) {
			int x;
			cin >> x;
			arr[i].push_back(x);
			if (arr[0][j] != x)
				diff[i].push_back(j);
			if (diff[i].size() > 4) {
				cout << "No\n";
				return 0;
			}
		}
		if (diff[w].size() < diff[i].size())
			w = i;
	}

	if (diff[w].size() < 3) {
		cout << "Yes\n";
		for (int i = 0; i < m; ++i)
			cout << arr[0][i] << " ";
		cout << "\n";
	}
	else {
		if (diff[w].size() == 3)
			diff[w].push_back(-1);
		for (int i = 0; i < 4; ++i)
			for (int j = i + 1; j < 4; ++j) {
				int x = diff[w][i], y = diff[w][j];
				bool c = false;
				if (y == -1) {
					y = x;
					c = true;
				}
				int prvx = arr[0][x], prvy = arr[0][y];
				arr[0][x] = arr[w][x];
				arr[0][y] = arr[w][y];
				bool flag = true;
				for (int l = 0; l < n; ++l) {
					vector<int> v;
					for (int k = 0; k < m; ++k)
						if (arr[0][k] != arr[l][k])
							v.push_back(k);

					if (v.size() == 3 && c) {
						for (int z = 0; z < 3; ++z) {
							int prv = arr[0][v[z]];
							arr[0][v[z]] = arr[l][v[z]];
							if (chk()) {
								cout << "Yes\n";
								for (int k = 0; k < m; ++k)
									cout << arr[0][k] << " ";
								cout << "\n";
								return 0;
							}
							arr[0][v[z]] = prv;
						}
					}

					if (v.size() > 2) {
						flag = false;
						break;
					}
				}
				if (flag) {
					cout << "Yes\n";
					for (int k = 0; k < m; ++k)
						cout << arr[0][k] << " ";
					cout << "\n";
					return 0;
				}
				arr[0][x] = prvx;
				arr[0][y] = prvy;
			}
		cout << "No\n";
	}

	return 0;
}