Steve
BAN USER
- 3of 3 votes
AnswersDesign a system for showing quotes on the web.
- Steve in United States
For example, when the user is looking at page A, part of which is reproduced in page B, the system could highlight part of page A present the user with a link to page B.
This is an open-ended system design question.
What constitutes a quote?
How do you find quotes?
How do you make it scale to the web?
How do you handle updates?
How would you arrange the servers?
What data structures would you use?
How much storage would you need?
How would the user agent present information about quotes?| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
AnswerImplement second/minute/hour/day counters Feb. 4, 2011 8:59pm
- Steve in United States
Implement the API that counts the number of events in the last sec/min/hr/day:
SMHDCounter {
void Increment();
int LastSecCount(); // also functions for minute, hour
int LastDayCount();
}
Additional requirements
- you require that the data be quite fresh
- how much storage will they take up
- make sure this works for an active counter, getting 100s of events a second.
- keep the implementation fast. E.g. under 10 mS. Or even better motivate by saying we might have 50 of these SMHD counters on a single status page, and ask the candidate how fast their solution should be.| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
Answersconsider a B2C website like Amazon, which will receive thousands requests from buyer per minutes. How will you design the "shop cart " component for it? where should the customs' shop cart data stored?
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
Answergeneric HashMap implementation
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
AnswersDesign a scalable server for the hangman game
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
AnswersHow do you search thrgough huge flat file?
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
AnswersDetermining trending topics
- Steve in United States
How do you think Twitter determines trending topics?
If needed, explain that trending topics are N most common occurring substrings across all tweets in a given time window, which is constantly moving. Later you can expand the question by putting the scale constraint considering the rate at which tweets come in, etc.| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
AnswersEstimate the # of unique strings with limited memory
- Steve in United States
Given a large array of strings S = [s1, s2, ... sN], determine Uniq(S) = how many unique strings there are in S.
(b) How large can N be to solve on one machine using only memory?
(c*) What if N is too large to fully fit in memory?| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
Answerscompare "write through cache" and "look aside cache"
- Steve in United States| Report Duplicate | Flag | PURGE
Google Software Engineer / Developer - 1of 1 vote
Answersimplement adding two unsigned numbers without using "+" or "++"
- Steve in United States| Report Duplicate | Flag | PURGE
Google Algorithm - 0of 0 votes
AnswersGiven a matrix with 1's and 0's, find the number of groups of 1's. A group is defined by horiz/vertically adjacent 1's.
- Steve in United States| Report Duplicate | Flag | PURGE
Google Algorithm - 0of 0 votes
AnswersGiven an array and a key, sum min subarray whose sum is no less than key. O(n) Time needed
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Algorithm - 0of 0 votes
Answerssingle machine,,given a dictionary(key->value),every entry takes 1KB,totally10 Million个entry,single mutex protecting the dictionary,mutex takes 512 Byte,What potential problems do you see and how would you address them?
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
AnswersImplement atof function. eg., +3.5e-2, .03e1, 1e1, 0.0
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Algorithm - 1of 1 vote
Answersgiving lots of intervals [ai, bi], find a point intersect with the most number of intervals
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Algorithm - 0of 0 votes
AnswersFInd the maximum sum of a sub-sequence from an positive integer array where any two numbers of sub-sequence are not adjacent to each other in the original sequence. E.g 1 2 3 4 5 6 --> 2 4 6
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Algorithm - 0of 0 votes
AnswersYou are given intervals of contiguous integers, like [1, 10), [15, 25), [40, 50), which are non-overlapping and of a fixed size.
- Steve in United States
Design a data structure to store these intervals and have the operations of insert, delete, and find functions| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Data Structures - 0of 0 votes
AnswersYou are going to take some numbers as an input from a file. You need to witer a program to find longest increasing sequence. You should process it as soon as you are taking an input. After finishing the last input immediately you should be able to tell the sequence. Input: 1 5 3 4 6 4 Output: 3 4 6
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Algorithm - 1of 1 vote
AnswersDesign the Facebook Credit system which is a application where users can buy/trade virtual currency and can use the virtual currency to purchase Facebook services, like paid apps.
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
AnswersDesign and implement an algorithm that would correct typos: for example, if an extra letter is added, what would you do?
- Steve in United States
design and implement algorithms that correct typos, offering guidance, encouragement, and confirmation along the way| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 1of 1 vote
AnswersImplement a read/write lock, given a mutex that has lock() and trylock() interface
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Application / UI Design - 0of 0 votes
Answersestimate the back-end capacity for mobile check in feature
- Steve in United States| Report Duplicate | Flag | PURGE
Application / UI Design - 1of 1 vote
AnswersGenerate a random 4 letter word from /usr/share/dict/words
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Algorithm - 0of 0 votes
AnswersIf you wanted to make a highly concurrent cache with a least recently used replacement policy, what data structures would you use? How would this scale per number of threads?
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Data Structures - 0of 0 votes
Answer• Design the recommendation system for search keywords
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
Answers• Design a system to support Facebook status update
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
AnswersDesign a system for showing quotes on the web?
- Steve in United States
For example, when the user is looking at page A, part of which is reproduced in page B, the system could highlight part of page A present the user with a link to page B.
What constitutes a quote?
How do you find quotes?
How do you make it scale to the web?
How do you handle updates?
How would you arrange the servers?
What data structures would you use?| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
AnswersFB has decided to award user who submits the billionth search query on a given day a car, by showing them a banner on their search result page. How would you implement such a system?
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
Answersdesign the backend system(data structure) of facebook's "like" button
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
AnswersDetermine winner of 2/9 number game
- Steve in United States
Two players play the following game: they pick a random number N (less than 2 billion) then,
starting from 1, take turns multiplying the number from the previous turn with either 2 or 9 (their choice).
Whoever reaches N first wins.
The candidate should write a function that given N decides who wins (first or second player)?| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Algorithm - 1of 1 vote
AnswersImplement a thread-safe Blocking queue in C/C++(POSIX) or Java
- Steve in United States| Report Duplicate | Flag | PURGE
Linkedin Software Engineer / Developer Data Structures - 0of 0 votes
Answersdesign a distributed system to find the 1000th visitor of google.com
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 2of 2 votes
AnswersDesign the backend for a Gmail-like mail system
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 0of 0 votes
Answersdesign and implement a memcache
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer System Design - 0of 0 votes
AnswersDesign a DHT
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Application / UI Design - 1of 1 vote
AnswersDesign a site similar to tinyurl.com
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Distributed Computing - 2of 2 votes
Answersgiven a stream of quotes for a stock from the last trading day. Assume its already time sorted. Find the maximum amount of money you could have made on this stock by making at most N transactions. A buy and a sell is counted as one transaction. For parts N = 1, N = 2 and N = Inf and the generic solution for N = some number (open ended)
- Steve in United States| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Algorithm - 1of 1 vote
Answersrange sum query,array,given i,j.
- Steve in United States
get sum array[i,j]:
requirement: n^1/2 space/time complexity| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Algorithm - 0of 0 votes
AnswersGiven: for every paper authored, there is a citation count vector. The h-index is a measure of researcher importance.
- Steve in United States
h-index: The largest number i such that there are i papers each with at least i citations.
1. Suppose that the citation-vector is sorted, how to efficiently compute the h-index?
2. Suppose that the citation-vector is not sorted, how to efficiencly compute the h-index? time complexity? an algorithm with time complexity n?| Report Duplicate | Flag | PURGE
Facebook Software Engineer / Developer Algorithm - 0of 0 votes
AnswersDefinition w-index: The largest number i such that there are i papers, with the lowest paper having at least one citation, the next one has at least two citations and so on, ith paper has i citations.
- Steve in United States
The citation vector is sorted. How efficiently can you compute the w index? Code this| Report Duplicate | Flag | PURGE
Facebook Algorithm - 0of 0 votes
Answers\e
- Steve in United States| Report Duplicate | Flag | PURGE
Data Structures - 0of 0 votes
AnswerGoogle is going to provide an over-the-wire service that the phone companies can use. This over-the-wire protocol will support three operations:
- Steve in United States
(1) void I_GAVE_OUT(n) -- the phone company is telling us that it handed out phone number (n).
(2) bool IS_TAKEN_(n) -- we are telling the phone company whether (n) is taken.
(3) number GIVE_ME_ONE() - the phone company is letting us tell them what number to hand out next.| Report Duplicate | Flag | PURGE
Two Sigma Software Engineer / Developer Data Structures
Replcarton941, Android test engineer at 8x8
My name is Lilly. I grew up in Somerset and currently live in the US. One desire that has always ...
RepI'm from India, 26 years old. I want to travel, I want a job where I can earn money ...
Repraginieharris, IIT Exam at Altera
I am Ragini, and I have lived in Washington for 2 years. My current job is Web Designer in Corinthian ...
Repjesusitahyer, Data Engineer at ASAPInfosystemsPvtLtd
Hello Everyone, I am Jesusita and I am passionate about writing the stories about powerful mantra to get what you ...
Repclarasbarr, Korean Air Change Flight at Adap.tv
I am ClaraBarr from California USA. Writes and records various different genres for television, film and other artists.Wrote several ...
RepI am Frank, 29 year old. I have worked with numerous branches, including payroll and human resources, which allows me ...
RepNatalieLutz, Applications Developer at Absolute Softech Ltd
Pitch trending story topics and continually look for ways to push breaking and/or viral stories forward with new angles ...
RepSpent 2001-2006 licensing the elderly in Jacksonville, FL. Spent 2001-2004 consulting about Break Up Spell. Spent two years deploying crickets ...
Repalinehchavez, SHOT 1500 NIGHT 5000 Call girls in Munirka Metro 9711794795 at Apple
Hi, I am Aline From New York USA. I am working as a Real estate rental agent in an Energy ...
Repkarmacknha, Accountant at Groupon
I am a forensic nurse . who has received specific education and training. I provide specialized care for patients who are ...
Repdianacloweryd, Developer Program Engineer at Accolite software
I am Diana from Reston USA . I work as an Agricultural and food science technician in Jumbo Sports. I help ...
Repnancysimms14, Backend Developer at ASAPInfosystemsPvtLtd
I am Nancy from California,Handling project development and documentation is my job. Passionate determined.Looking for an open project ...
Repsallieroliphant, Project Leader at Wissen Technology
With years of experience I can guarantee you that our licensed company specializes in furnace maintenance scarborough, air conditioners and ...
Repaaronlustera, Android test engineer at Absolute Softech Ltd
My job is to help groups of people work together better, understand their common goals, and plan to achieve those ...
RepPrankHwa, Animator at Accolite software
I am a Reporter and responsible for delivering updates and analysis on current events with the main goal to keep ...
Repmonamore609, Android test engineer at Cisco Systems
Data entry clerks are responsible for inputting a high volume of data from multiple sources into a database, ensuring that ...
Repannavhedge4, AT&T Customer service email at ABC TECH SUPPORT
Hi everyone, I am from Worcester,USA. I currently work in the Argus Tapes & Records as Scientific illustrator . I love ...
RepHenryMelvin, Korean Air Change Flight at AMD
Hello, everybody! My name is Henry,I am a picture-drawer.Art drawing & painting classes for adults, kids, teens.We have ...
I mean go over. What do you mean by Else the better of (opposite of F(i+1, j)) and (opposite of F(i, j+1))?
- Steve September 21, 2012Could you write codes using DP?