OA:
Subtree of Another Tree
Search a 2d matrix 2
3 轮:
- 第一轮:
-Find the first unique element in a stream(https://leetcode.com/discuss/interview-question/algorithms/124822/bloomberg-interview-question-find-first-unique-integer-in-a-stream)
- Tell me a difficult situation you faced and how you overcame it?
- Tell me a goal you achieved
- 第二轮:
- AWS has a catalogue of items. Each item has a age range for users, (example, itemA has age range 3-5, itemB has range 5 onwards). Use classes to design this catalogue. Write a function that returns all the items can be allowed for a given age range.
Example: ItemA(3,5), ItemB(4-7), ItemC(2-8), ItemD(5-Onwards)
Input: Range(4-10)
Output: ItemB, ItemD - Tell me a project you did, why was it challenging? What did you learn from it?
- 第三轮:
- Tell me a time you took a tough decision.
- 1st question: convert [‘a’,‘b’,‘b’,‘c’,‘d’,‘c’,‘e’] to [‘a’,‘b’,‘c’,‘d’,‘e’]
- 2nd question: Given a string e.g." hello world", convert it to a string sorted with characters by frequency and if the frequency is the same sort it on the basis of order.
e,g, “hello world”
Output: “lohe wrld” - 3rd question: Longest substring with at the most k characters
https://leetcode.com/problems/longest-substring-with-at-most-k-distinct-characters/