#include <bits/stdc++.h>
using namespace std;
long long n, m, s[2005];
bool tot[2005][2005];
int main() {
  cin >> n >> m;
  for (long long i = 0; i < n; i++) {
    string iii;
    cin >> iii;
    for (long long j = 0; j < m; j++) {
      if (iii[j] == '1') {
        tot[i][j] = true;
        s[j]++;
      }
    }
  }
  bool ok = false;
  for (long long i = 0; i < n; i++) {
    bool cur = true;
    for (long long j = 0; j < m; j++) {
      if (tot[i][j] && s[j] == 1) cur = false;
    }
    if (cur) ok = true;
  }
  if (!ok)
    cout << "NO\n";
  else
    cout << "YES\n";
  return 0;
}
