#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m;
  cin >> n >> m;
  char save[n][m + 1];
  int d[m];
  for (int i = 0; i < m; i++) d[i] = 0;
  for (int i = 0; i < n; i++) {
    cin >> save[i];
    char *s = save[i];
    for (int j = 0; j < m; j++) {
      if (s[j] == '1') d[j]++;
    }
  }
  for (int i = 0; i < n; i++) {
    char *s = save[i];
    int j = 0;
    do {
      if (s[j] == '1' && d[j] < 2) break;
      j++;
    } while (j != m);
    if (j == m) {
      cout << "YES";
      return 0;
    }
  }
  cout << "NO";
  return 0;
}
