#include <bits/stdc++.h>
#pragma GCC optimize("O2")
using namespace std;
const int maxn = 2000 + 10;
int n, m, sum[maxn];
char s[maxn][maxn];
int32_t main() {
  scanf("%d%d", &n, &m);
  for (int i = 0; i < n; i++) {
    scanf("%s", s[i]);
  }
  for (int j = 0; j < m; j++) {
    for (int i = 0; i < n; i++) {
      sum[j] += (s[i][j] == '1');
    }
  }
  bool ans = 0;
  for (int i = 0; i < n; i++) {
    bool ok = 1;
    for (int j = 0; j < m; j++) {
      int a = (s[i][j] == '1');
      ok &= (a < sum[j]);
    }
    ans |= ok;
  }
  printf(ans ? ("YES\n") : ("NO\n"));
}
