#include <bits/stdc++.h>
int dr[] = {2, 2, -2, -2, 1, -1, 1, -1};
int dc[] = {1, -1, 1, -1, 2, 2, -2, -2};
int dr1[] = {0, 0, 1, 1, 1, -1, -1, -1};
int dc1[] = {1, -1, 1, 0, -1, 0, 1, -1};
int dr2[] = {0, 0, 1, -1};
int dc2[] = {1, -1, 0, 0};
using namespace std;
long long int chec(long long int a, long long int b) {
  char t[10], t1[10];
  long long int s = 0, s1 = 0;
  while (a != 0) {
    t[s++] = a % 2 + '0';
    a /= 2;
  }
  t[s] = '\0';
  while (b != 0) {
    t1[s1++] = b % 2 + '0';
    b /= 2;
  }
  t1[s1] = '\0';
  long long int k = min(s, s1);
  for (long long int i = 0; i < k; i++) {
    if (t[i] == '1' && t1[i] == '1') return -1;
  }
  return 1;
}
int main() {
  long long int i, j, n, k, s, x;
  while (cin >> n >> k) {
    vector<long long int> v;
    map<long long int, long long int> mp;
    for (i = 1; i <= n; i++) {
      s = 0;
      for (j = 1; j <= k; j++) {
        cin >> x;
        s = s + (x << (j - 1));
      }
      if (mp[s] == 0) v.push_back(s);
      mp[s] = 1;
    }
    bool f = 0;
    sort(v.begin(), v.end());
    if (v[0] == 0) f = 1;
    for (i = 0; i < v.size(); i++) {
      for (j = 0; j < v.size(); j++) {
        if (chec(v[i], v[j]) == 1) {
          f = 1;
        }
      }
    }
    if (f == 1)
      cout << "YES" << endl;
    else
      cout << "NO" << endl;
  }
  return 0;
}
