#include using namespace std; typedef long long ll; #define REP(i,n) FOR(i,0,n) #define FOR(i,a,b) for(ll i=a;i vi; typedef vector> vvi; const ll INF = (1ll << 30); typedef pair pii; typedef vector> Graph; typedef vector vpii; int main() { ll n,m; cin>>n>>m; vpii v(m); REP(i,m) cin>>v[i].first>>v[i].second; auto comp=[](pii a,pii b) {return a.second>b.second;}; sort(ALL(v),comp); vi cost(n); for(pii p:v) { if(cost[p.first]||cost[p.second]) continue; cost[p.first]=1; } bool active=false; reverse(ALL(cost)); REP(i,n) { if(cost[i]) { cout<<1; active=true; }else if(active) { cout<<0; } } cout<