Facebook | E5 | New York | Sep 2019 [No Offer]
Anonymous User
2970

YOE: 10+
Big O for all coding questions

Round 1: 30 min Behavioral + 10 min Coding + 5 min Q's to interviewers

  • Matrix Antidiagonal Traverse Ran out of time (I think they gave me 5, instead of 10 min for this) when writing on whiteboard. Was not allowed to finish, but switched to asking questions instead.

Round 2: 40 min Coding + 5 min Q's to interviewers

Round 3: 40 min System Design + 5 min Q's to interviewer

Round 4: 40 min Coding + 5 min Q's to interviewers

  • warm up (10 min): calculate tax from brackets

    Calculate tax if Salary and Tax Brackets are given as: calculateTax(double salary, Double[][] brackets)
    e.g. Salary = 35000
    Brackets = [ [10000, 0.1],[20000, 0.2], [10000, 0.3], [null, .4]]
    null being rest of the salary

  • core challenge (30 min): print tree column-wise
    https://leetcode.com/problems/vertical-order-traversal-of-a-binary-tree/
    Sort and print is O(N logN)
    Can you do it in O(N) if you don't need to sort elements that fall into the same row/column, but put them in the order of traversal?
    I think I got it but was running really low on time towards the end.

Comments (3)