def find(N,trust):
res=[0]*(N+1)
for a,b in trust:
res[a]-=1
res[b]+=1
for a,i in enumerate(res[1:]):
if i==N-1:
return a+1
return -1
def find(N,trust):
res=[0]*(N+1)
for a,b in trust:
res[a]-=1
res[b]+=1
for a,i in enumerate(res[1:]):
if i==N-1:
return a+1
return -1