import java.io.BufferedInputStream; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.*; public class _479 { public static void main(String[] args) throws IOException { new _479().solve(); } void solve() throws IOException { try (final Scanner in = new Scanner(System.in)) { int n = in.nextInt(); int m = in.nextInt(); List[] g = new List[n]; for (int i = 0; i < n; i++) g[i] = new ArrayList<>(); int[] cnt = new int[n]; for (int i = 0; i < m; i++) { int a = in.nextInt(); int b = in.nextInt(); cnt[a < b ? a : b]++; if (a < b) g[b].add(a); else g[a].add(b); } char[] cs = new char[n]; Arrays.fill(cs, '0'); for (int i = n-1; i >= 0; i--) if (cnt[i] != 0) { for (int t : g[i]) cnt[t]--; cs[n-1-i] = '1'; } for (int i = 0; i < n; i++) { if (cs[i] != '0' || i == n - 1) { System.out.println(new String(cs, i, cs.length - i)); return; } } } } // for debug static void dump(Object... o) { System.err.println(Arrays.deepToString(o)); } }