Google SE Full stack screening round
Anonymous User
1049

Asked in Google full stack screening round:
Suppose we have a social network consisting of people and their friends.
We call a person a “newbie” if they have exactly one friend.
We call a person a “facilitator” if all, except possibly one, of its friends are newbies.
A facilitator must have at least one newbie friend.

Write an algorithm to find all “facilitators” in a social network.

Wasnt able to tell which data structure to use but the interviewer was helpful gave me a example data structure and asked me write the algorithm for finding the facilitators based on that.

I dont think i am gonna get selected, let me know how to approach this prob.
Thanks in advance

Comments (5)