#include <bits/stdc++.h>
using namespace std;
char a[2000][2005];
int c[2000];
int main() {
  int i, j, m, n;
  bool t;
  for (i = 0; i < 2000; i++) c[i] = 0;
  cin >> n >> m;
  for (i = 0; i < n; i++) cin >> a[i];
  for (i = 0; i < n; i++)
    for (j = 0; j < m; j++)
      if (a[i][j] == '1') c[j]++;
  for (i = 0; i < n; i++) {
    for (j = 0; j < m; j++)
      if (a[i][j] == '1') c[j]--;
    t = true;
    for (j = 0; j < m; j++)
      if (c[j] <= 0) {
        t = false;
        break;
      }
    if (t) {
      cout << "YES" << endl;
      return 0;
    }
    for (j = 0; j < m; j++)
      if (a[i][j] == '1') c[j]++;
  }
  cout << "NO" << endl;
  return 0;
}
