Facebook Interview Report
- 4of 4 votes
AnswersDescribe the actions performed by two functions:
- asafiniu February 27, 2013 in United States
Publish(user, msg) - publishes a new post on behalf of 'user'
GetNewsFeed(user) - gathers 30 posts from 'user's friends to show on his/her news feed.
I was asked to map out the relations required for holding large amounts of data.
As a followup, I had to calculate the number of machines facebook would have to initially buy to start off using this news feed.| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer System Design - 10of 10 votes
AnswersGiven a function KNOWS(A,B), which returns 1 if A knows B (and not necessarily the other way around) and 0 if A does not know B.
- asafiniu February 27, 2013 in United States
A Celebrity is one who does not know anyone,
and one who is known by everybody.
For a list of N people, find all celebrities in linear time.| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Algorithm - 0of 0 votes
AnswersConvert a string of Roman numerals to an integer in O(n) time
- asafiniu February 27, 2013 in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Algorithm
CareerCup is the world's biggest and best source for software engineering interview preparation. See all our resources.