#include <bits/stdc++.h>
using namespace std;
long long a[2005][2005];
long long c[2006];
int main(int argc, char const *argv[]) {
  long long i, j, n, m;
  cin >> n >> m;
  string s;
  for (i = 0; i < n; ++i) {
    cin >> s;
    for (j = 0; j < m; ++j) {
      a[i][j] = s[j] - '0';
      c[j] = 0;
    }
  }
  for (i = 0; i < m; ++i) {
    for (j = 0; j < n; ++j) {
      c[i] += a[j][i];
    }
  }
  long long ans = 0;
  for (i = 0; i < n && ans == 0; ++i) {
    long long flag = 0;
    for (j = 0; j < m && flag == 0; ++j) {
      if (a[i][j] == 1 && c[j] == 1) {
        flag = 1;
      }
    }
    if (flag == 0) {
      ans = 1;
    }
  }
  if (ans == 1) {
    cout << "YES"
         << "\n";
  } else {
    cout << "NO"
         << "\n";
  }
  return 0;
}
