Thursday, April 18, 2019

Leetcode 75: Sort Colors

April 20, 2019

Introduction


It is so much fun to work on this algorithm this Saturday morning. I like to write down my feeling and experience. Thank you Microsoft.

Learning is hard and fun


I worked on the algorithm after mock interview on April 19, 2019. After one hour 29 minutes interview with an anonymous interviewee from 10:00 PM to 11:29 PM, the interviewee shared a lot of his onsite experience with Google.

I started to work on the algorithm Leetcode 75 Sort color again. I could not make it work based on the study of code in the most popular discussion link.

I went to bed and came back Saturday morning. But my thought is "life is tough." Problem solving of 75: Sort Colors is more than I expected.

I expected to practice 5 mock interview on April 19, but I did not do any since I had so many activities to fill, follow up study of previous day mock interview, 401 K study with classmate, and mock interview etc.

My drawing


I spent time to work on the test case [2, 0, 1, 2], and figure out how to do it on paper first this time.


Here is my discussion post on Leetcode.com.

I got a code assessment invitation on May 18 from Microsoft. That is the reason I work on Leetcode mock interview and came cross this algorithm.

No comments:

Post a Comment