Given n people and a list of pairs representing friendships where person a knows person b (friendships are transitive: if x knows y and y knows z, then x knows z), find the number of pairs of people…
You've read your 3 free write-ups
Sign up free to keep reading. Your account opens the first 10 questions of every company.