Meta Frontend Virtual Onsite Interview

Improve a Function and Find the node in identical A/B DOM tree

Onsite: Coding Round 1:
Question 1: DOM store (cannot use symbol)
Question 2: Implement unit test:
it(“should be an equal number”, () => {
// logs: "success: should be an equal number "
// or “failure: should be an equal number” if expect(1).toBe(2)
I have never done the second question completely, and I was confused right away. Does it mean if one question is not answered correctly, it’s a fail?

Round 2 will be on the next day, will catch up tomorrow

Coding Round 2:

  1. Implement throttle with differences from BFE requirements
  2. Debounce
  3. ClearAllTimeout requires O(1)