## Find the Town Judge

```
def find_judge(n, trust)
return 1 if n == 1
people = Array.new(n, 0)
trust.each do |truster, trustee|
people[trustee - 1] += 1
people[truster - 1] = -1.0/0.0 # -Infinity
end
people.index(n-1) ? people.index(n-1) + 1 : -1
end
```