Lately I've been trying to adjust how I deal with failure. A yoga teacher told me a while back, "Rejection is redirection." Getting rejected might also be a reminder to change direction. I also read about someone who didn't get into the company they loved the first three times and finally made it on the fourth try.
Maybe I'll move on to other opportunities, or maybe I'll try Nuro again after I've built up my interview skills more solidly. Either way, here's what I learned from this Nuro C++ interview, which was also the first C++ interview of my life.
The problem can be understood as a variant of LC 23 (Merge k Sorted Lists), except that each element carries other data in addition to a timestamp.
Defining the data types / structs clearly solves half of the problem. Don't think only about the merge algorithm; also think through how the data is represented, what state the class needs to maintain, and how the interface is organized. I'd suggest also practicing the "Design X" type of problems on LC, to stay familiar with overall class design.
And don't forget to practice writing your own test cases in C++. We're used to the test frameworks that LeetCode-style platforms provide, but in an interview you also need to be able to build the inputs yourself and check the outputs.
If this post helped you, silently wish me luck. Maybe the universe will pick it up and make my next interview, at another self-driving company, go a bit better. Good luck to everyone too!
Discussion
Loading comments…