"Initially I asked clarifying questions like whether the tree can be empty or not and asked the interviewer to explain what is meant by left view and the explanation for the sample inputs.
Then I came up with the level order traversal approach where we visit each level in the binary tree at once using a queue and at each level print the value of the first node.
Interviewer seemed satisfied with the approach and asked me to code it up.
Finally gave the time and space complexity of the solution."
Ds S. - "Initially I asked clarifying questions like whether the tree can be empty or not and asked the interviewer to explain what is meant by left view and the explanation for the sample inputs.
Then I came up with the level order traversal approach where we visit each level in the binary tree at once using a queue and at each level print the value of the first node.
Interviewer seemed satisfied with the approach and asked me to code it up.
Finally gave the time and space complexity of the solution."See full answer
"Situation - A time I saw a peer struggling was while I was at Google working in Mountain View. A fellow colleague of mine was consistently not meeting standards in his performance reviews and wasn’t sure why. He was upset because Google was his dream company and he wasn’t sure how to improve based on his feedback.
Task - I was tasked to design a based VUI framework for our discovery space on smart displays. This colleague was acting as the VUI lead for the project while I acted as t"
Ben G. - "Situation - A time I saw a peer struggling was while I was at Google working in Mountain View. A fellow colleague of mine was consistently not meeting standards in his performance reviews and wasn’t sure why. He was upset because Google was his dream company and he wasn’t sure how to improve based on his feedback.
Task - I was tasked to design a based VUI framework for our discovery space on smart displays. This colleague was acting as the VUI lead for the project while I acted as t"See full answer
"Whenever I find resistance to my idea, my general approach is to :
Validate my idea
Identify if it is a political reason or is it a valid engineering tech reason
Assuming it is not political but it is resource/difference of opinions that are causing resistance.
Then I would try to do a quick POC and show a value proposition for the idea to get the buy-in.
One similar situation happened
The situation was that stakeholders were promised a feature that would decrease their number of ticket"
Jaim - "Whenever I find resistance to my idea, my general approach is to :
Validate my idea
Identify if it is a political reason or is it a valid engineering tech reason
Assuming it is not political but it is resource/difference of opinions that are causing resistance.
Then I would try to do a quick POC and show a value proposition for the idea to get the buy-in.
One similar situation happened
The situation was that stakeholders were promised a feature that would decrease their number of ticket"See full answer
"I'm seeking a role in which I can be continually challenged to devise innovative and streamlined solutions for complex issues, particularly with regard to the persistent soaking problem. I'm excited about the opportunity to not only excel in my own performance but also to empower and enable my colleagues to perform at their absolute best. My goal is to wield my influence and magnetic qualities to not only attract but also retain top-tier engineering talent, all in alignment with our shared objec"
Anonymous Narwhal - "I'm seeking a role in which I can be continually challenged to devise innovative and streamlined solutions for complex issues, particularly with regard to the persistent soaking problem. I'm excited about the opportunity to not only excel in my own performance but also to empower and enable my colleagues to perform at their absolute best. My goal is to wield my influence and magnetic qualities to not only attract but also retain top-tier engineering talent, all in alignment with our shared objec"See full answer
"from typing import List
def traprainwater(height: List[int]) -> int:
if not height:
return 0
l, r = 0, len(height) - 1
leftMax, rightMax = height[l], height[r]
res = 0
while l < r:
if leftMax < rightMax:
l += 1
leftMax = max(leftMax, height[l])
res += leftMax - height[l]
else:
r -= 1
rightMax = max(rightMax, height[r])
"
Anonymous Roadrunner - "from typing import List
def traprainwater(height: List[int]) -> int:
if not height:
return 0
l, r = 0, len(height) - 1
leftMax, rightMax = height[l], height[r]
res = 0
while l < r:
if leftMax < rightMax:
l += 1
leftMax = max(leftMax, height[l])
res += leftMax - height[l]
else:
r -= 1
rightMax = max(rightMax, height[r])
"See full answer