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 JAVA):

Solution:
import java.io.*;
import java.util.*;
 
import java.math.*;
import java.awt.Point;
 
public class CFTemplate {
    static final long MOD = 1000000007L;
    //static final long MOD2 = 1000000009L;
    //static final long MOD = 998244353L;
    //static final long INF = 500000000000L;
    static final int INF = 1100000000;
    static final int NINF = -100000;
    static FastScanner sc;
    static PrintWriter pw;
    static final int[][] dirs = {{-1,0},{1,0},{0,-1},{0,1}};


    static int[][] nums;
    public static void main(String[] args) {
        sc = new FastScanner();
        pw = new PrintWriter(System.out);

        int N = sc.ni();
        int M = sc.ni();
        nums = new int[N][M];
        for (int i = 0; i < N; i++)
            nums[i] = sc.intArray(M, 0);

        for (int i = 1; i < N; i++) {
            ArrayList<Integer> inds = diffs(0,i);
            if (inds.size()==5) {
                pw.println("No");
                pw.close();
                return;
            } else if (inds.size()==4) {
                for (int x: new int[]{3,5,6,9,10,12}) {
                    int[] ans = nums[0].clone();
                    for (int b = 0; b < 4; b++) {
                        if ((x&(1<<b)) > 0)
                            ans[inds.get(b)] = nums[i][inds.get(b)];
                    }
                    boolean good = true;
                    for (int j = 0; j < N; j++) {
                        if (check(j,ans) > 2) {
                            good = false;
                            break;
                        }
                    }
                    if (good) {
                        pw.println("Yes");
                        for (int A: ans)
                            pw.print(A + " ");
                        pw.close();
                        return;
                    }
                }
                pw.println("No");
                pw.close();
                return;
            } else if (inds.size()==3) {
                for (int unk = 0; unk < 3; unk++) {
                    for (int a = 0; a < 2; a++) {
                        for (int b = 0; b < 2; b++) {
                            int[] ans = nums[0].clone();
                            ans[inds.get(unk)] = -1;
                            int j1 = inds.get((unk+1)%3);
                            int j2 = inds.get((unk+2)%3);
                            ans[j1] = a==0 ? nums[0][j1] : nums[i][j1];
                            ans[j2] = b==0 ? nums[0][j2] : nums[i][j2];
                            int[] print = works(ans,inds.get(unk));
                            if (print != null) {
                                pw.println("Yes");
                                for (int A: print)
                                    pw.print(A + " ");
                                pw.close();
                                return;
                            }
                        }
                    }
                }
                pw.println("No");
                pw.close();
                return;
            }
        }
        pw.println("Yes");
        for (int A: nums[0])
            pw.print(A + " ");
        pw.close();
    }

    public static int[] works(int[] ans, int u) {
        for (int r = 0; r < nums.length; r++) {
            int d = check(r,ans);
            boolean canfix = (ans[u]==-1);
            if (d > 3 || (d==3 && !canfix)) {
                return null;
            } else if (d==3 && canfix) {
                ans[u] = nums[r][u];
            }
        }
        if (ans[u]==-1)
            ans[u] = nums[0][u];
        return ans;
    }

    public static ArrayList<Integer> diffs(int r1, int r2) {
        ArrayList<Integer> inds = new ArrayList<>();
        for (int j = 0; j < nums[0].length; j++) {
            if (nums[r1][j]!=nums[r2][j]) {
                inds.add(j);
                if (inds.size()==5) break;
            }
        }
        return inds;
    }

    public static int check(int r, int[] guess) {
        int d = 0;
        for (int j = 0; j < nums[r].length; j++) {
            if (guess[j] != nums[r][j])
                d++;
        }
        return d;
    }
 
    static class FastScanner {
        BufferedReader br;
        StringTokenizer st;

        public FastScanner() {
            br = new BufferedReader(new InputStreamReader(System.in), 32768);
            st = null;
        }
 
        String next() {
            while (st == null || !st.hasMoreElements()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
            return st.nextToken();
        }
 
        int ni() {
            return Integer.parseInt(next());
        }
 
        int[] intArray(int N, int mod) {
            int[] ret = new int[N];
            for (int i = 0; i < N; i++)
                ret[i] = ni()+mod;
            return ret;
        }
 
        long nl() {
            return Long.parseLong(next());
        }
 
        long[] longArray(int N, long mod) {
            long[] ret = new long[N];
            for (int i = 0; i < N; i++)
                ret[i] = nl()+mod;
            return ret;
        }
 
        double nd() {
            return Double.parseDouble(next());
        }
 
        String nextLine() {
            String str = "";
            try {
                str = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            return str;
        }
    }
}