#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m, f[2001] = {0}, i, j;
  char c;
  scanf("%d%d", &n, &m);
  vector<int> v[n + 1];
  for (i = 1; i <= n; i++) {
    for (j = 1; j <= m; j++) {
      scanf(" %c", &c);
      if (c == '1') {
        v[i].push_back(j);
        f[j]++;
      }
    }
  }
  for (i = 1; i <= n; i++) {
    int flag = 1;
    int s = v[i].size();
    for (j = 0; j < s; j++) {
      if (f[v[i][j]] == 1) {
        flag = 0;
        break;
      }
    }
    if (flag == 1) {
      printf("YES");
      return 0;
    }
  }
  printf("NO");
  return 0;
}
