Baidu

  www.baidu.com
Work in HR? Unlock Free Profile

Baidu Software Engineer Interview Question

I interviewed in Beijing, Beijing (China) and was asked:
"Given a 10G user action log file, and each each in the log is userID-actionID format, also give you a PC with 4G memory, find a way to search for those userIDs that has at least three action records."
Add Tags [?]
Answer

Part of a Software Engineer Interview Review - one of 25 Baidu Interview Reviews

Answers & Comments

0
of 0
votes
I failed in this question, I cannot find a way to do it beside use external sort to sort the file, and go through the file to find the record. However, I think this can be solve by using map reduce idea on a single machine(or hadoop on single node). (M/R and hadoop can be found on wiki)
- Interview Candidate on Oct 3, 2011

To comment on this question, Sign In with Facebook or Sign Up

Tags are like keywords that help categorize interview questions that have something in common.