Google L3 Phone Screen Question

Anonymous User
465
Feb 09, 2025
Feb 13, 2025

Given a stream of data in the format:
[timestamp] Alice called Bob
[timestamp] Alice called Charlie
.....
and a List of people [Alice, Bob, Charlie .. ]
When a person calls the other, they become friends and anyone they are friends with also become their friend.

Determine the timestamp when all users become friends with each other.

Comments (5)