#include <bits/stdc++.h>
using namespace std;
int main(int argc, char const *argv[]) {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int n, m;
  cin >> n >> m;
  vector<vector<int> > G(n + 5, vector<int>(0));
  int c[m + 5][2];
  memset(c, (0), sizeof(c));
  for (int i = 1; i <= m; i++) {
    int l, r;
    cin >> l >> r;
    for (int j = l; j <= r; j++) G[j].push_back(i);
  }
  int ans[n + 5];
  for (int i = 1; i <= n; i++) {
    int rs = 0, ls = 0;
    int put = 0;
    for (int j = 0; j < int(G[i].size()); j++) {
      int v = G[i][j];
      rs += c[v][0];
      ls += c[v][1];
      if (rs > ls)
        put = 1;
      else
        put = 0;
    }
    ans[i] = put;
    for (int j = 0; j < int(G[i].size()); j++) {
      int v = G[i][j];
      c[v][put]++;
    }
  }
  for (int i = 1; i <= n; i++) cout << ans[i];
  cout << '\n';
  return 0;
}
