Is LeetCode Relevant?
LeetCode helps you pass coding interviews, but does it actually matter in real life? If it's irrelevant, why has it become the industry standard?
Cracking the Coding Interview
Over the years, LeetCode has become the unofficial standard for testing coding skills. Many software engineers desperate to crack the FAANG coding interviews have given themselves away to the dreadful LeetCode grind. But there's one doubt in the minds of all job seekers grinding LeetCode, and that is, "Is LeetCode actually relevant in real life?" If you've grinded LeetCode at least once, you probably had the same question. So ARE coding interviews a good measure to test our coding skills? Well, let's find out.
Coding-related Books
A quick announcement before we move on. Due to a popular request, I included my personal recommendation on coding-related books. Whether you are a beginner curious about learning to code or someone looking to improve your DSA skills, feel free to check it out below.
Why LeetCode-style Interviews?
Alright. Going back to the question. Is LeetCode actually relevant in real life? Let me turn the wheels a bit and ask you this way. Why do you think companies adopted LeetCode-style questions in the first place? They all agree that the software engineers they hire won't ever have to do stuff like inverting a binary tree, reversing a linked list, or even "counting the number of islands," for that matter. But then why? Why is the industry going all in with what appears to be more of an academic exam? It's because this is an interview. And companies can only invest so much in evaluating every candidate.
By analyzing a candidate's performance on LeetCode-style questions, companies can quickly identify those with the skills and knowledge needed to succeed in the software engineering field. And remember, guys. Recruiting is also a competition. Companies don't have the resources to look into every detail of a candidate's work history and education. On the other hand, LeetCode-style questions provide a fair and objective way for them to compare candidates with similar backgrounds and experiences. By using these types of questions, they can better understand who would be the best fit for the job.
Engineering Best Fit
Guys, don't get me wrong, though. I'm not trying to take sides. Instead, I'm just trying to be objective and realistic. Think of it this way. What would you do if you were the employer? Would you ask every candidate to elaborate on how they would build a platform? What if they lie? How would you distinguish? And say you're interviewing a new grad. They have similar backgrounds and experiences with their only difference being their coding performance. Who would you choose? Wouldn't you extend the offer to the higher-scoring candidate? It’s fair. 🤷 In summary, LeetCode-style questions test candidates' understanding of data structures, algorithms, and software engineering fundamentals. By assessing their knowledge of these topics, companies can ensure they are hiring well-equipped problem solvers to handle their software engineering needs.
LeetCode Matters… Somewhat
So then. Is LeetCode absolutely irrelevant to our daily work? Does it not have any real-life examples? That I'm afraid I have to disagree. For example, let me show you some real-life applications. Number one, Alexa, what's the population of the US? "According to the 2020 US Census, the population of the United States is 331 million people, which is a 7.1% increase over the 2010 US Census." How do you think the virtual assistant verbalized 331 million people? What about the numbers 2020 and 7.1%? If you feed it a numerical input, it doesn't magically say the numbers in English directly. Instead, several procedures are involved. It would:
Identify the language.
Convert the numbers into English words.
Spell the numbers out.
Read the words one by one.
🔢 According to the 2020 US Census, the population of the United States is 331 million people, which is a 7.1% increase over the 2010 US Census.”
🔤 According to the twenty-twenty US Census, the population of the United States is three hundred thirty-one million people, which is a seven-point one percent increase over the twenty-ten US Census.
Which LeetCode question captures that? Integer to English Words.
Next example. What about highlighting the words in Kindle? What if I highlight here, highlight there, then highlight here, so it overlaps with both? Looks familiar? Merge Intervals. Next example. What's the data structure used in autocomplete? Trie. Next. What about game applications? What game shares the same algorithm used in Word Search? Candy Crush. You see, LeetCode problems are not entirely irrelevant; some ARE used in real life.
Companies won’t change…
Now, I know I'm using only a tiny subset of LeetCode problems to strengthen my argument; I agree that most aren’t that relevant. Despite that, do I still recommend grinding LeetCode? The answer's yes.
Companies aren't going to change the game rules. If you have to face it at some point in your life anyway, you might as well start now. The good news is that it can be learned and improved with practice. But more on that later. 😉
Time and space complexities are relevant. Not only that, complexity analysis is crucial. Even if you get the implementation right, you can still fail the interview if you get the complexity analysis wrong.
It improves your algorithmic and problem-solving skills. With solid fundamentals in computer science, you'll start to think about the best data structure and the most optimal algorithm to incorporate into your solutions.
That's the power of LeetCode. You lay a strong foundation needed in building the architecture. Ultimately, that's the kind of candidate the companies are looking for; the engineer who can accomplish more with less.
How to Improve LeetCoding Skills
Let's move on to the last topic of this video. How can I improve my LeetCoding skills? How can I get better at it? If you're looking for an effective study plan, watch my video on How to Use LeetCode Effectively. You can also visit my website for more detailed resources on LeetCode prep. For example, my study guide, a LeetCode cheat sheet, and some common templates and tricks that come in handy for the interviews. Remember to check out the books I recommend on coding in the descriptions below. Lastly, please like and subscribe if you found this video helpful. Thanks for watching. I'll see you at the next one. Bye.