#include <bits/stdc++.h>
using namespace std;
const int maxn = 100005;
int a[5];
int f[20];
int main() {
  int n, k, x;
  while (~scanf("%d%d", &n, &k)) {
    memset(f, 0, sizeof(f));
    for (int i = 0; i < n; i++) {
      int cnt = 0;
      for (int j = 0; j < k; j++) {
        scanf("%d", &x);
        cnt = cnt * 2 + x;
      }
      f[cnt]++;
    }
    if (f[0]) {
      printf("YES\n");
      continue;
    }
    int flag = 0;
    for (int i = 0; i <= 16; i++) {
      for (int j = 0; j <= 16; j++) {
        if (f[i] && f[j] && i != j) {
          memset(a, 0, sizeof(a));
          int xx = i, yy = j;
          int pos = 0;
          while (xx) {
            a[pos++] += xx % 2;
            xx >>= 1;
          }
          pos = 0;
          while (yy) {
            a[pos++] += yy % 2;
            yy >>= 1;
          }
          int count = 0;
          for (int o = 0; o < 4; o++) {
            if (a[o] <= 1) count++;
          }
          if (count == 4) {
            flag = 1;
            break;
          }
        }
      }
      if (flag) break;
    }
    if (flag)
      printf("YES\n");
    else
      printf("NO\n");
  }
  return 0;
}
