“Software is a great combination between artistry and engineering.”
– Bill Gates
In college, I wanted to learn to build things that would have a significant and positive impact on mankind. I looked around and saw that there were people and organizations out there that were doing this on a daily basis. They were pushing the human race forward with their numerous contributions to society. But unfortunately for me, I was not able to find anyone/anything that could show me the path to these organizations or offer me the necessary guidance toward cracking their coding interviews. I discovered how to ace coding interviews the hard way, by getting knocked from one resource to another, finally securing offers from HackerEarth, Microsoft, Airbus and GeeksforGeeks in my final year. This was why I wanted to share my learning with whoever’s now looking for that guide. They can invest their time and energy in the right direction from the very beginning.
A lot of people who are job hunting want to know just how to land a great job at a swanky company. They want to know what are all the types of questions asked in their interviews and the topics that they should prepare for. If you are one of those people, you are in the right place. We hope that we will be able to help you prepare and ace your coding interviews!
So, you want to hold a cool job as a Software Engineer in FAANG (Facebook, Amazon, Apple, Netflix and Google), eh? Not that it’s wholly impossible but let’s backtrack a bit.
You first need to know everything that your interviewer wants to know about you. To be able to crack their coding interview, you need to broadly exhibit these 3 important skills:
- Problem Solving Ability (Data Structures and Algorithms)
These make up the bulk of the coding interviews. The intent here is to assess your problem-solving skills and the questions are typically around concepts of Algorithms and Data Structures. A rookie mistake to make during these interviews is to start coding too soon. In the first 10 minutes of the interview, try seeking more clarity on the question. For example, try asking details of the expected input with questions like “Will there be any negative inputs?” and explaining the solution approach. It also helps to think out loud, that way the interviewer gets to understand your thought process and, if you are lucky, gives you hints early on if he/she sees you going in the wrong direction. Only begin writing code once you and your interviewer agree that this is the best possible approach for the solution.
- Domain knowledge (includes core subjects of CS)
Object-Oriented Programming (OOP), Operating Systems, Databases, Computer Networks, Caching and Web Technologies.
- Communication skills
This might seem like a cliche but trust me it is not. A large part of what developers do daily involves effective communication and collaboration. Communication is not just knowing what to say – it is about the how, the when, and the where, as well. You need to know how to put your point across with just the right level of detail; you need to know when to ask for help and not be the cause for decreased levels of productivity; and finally – you should know where, i.e, in which channels you need to communicate in, so your information doesn’t get lost and reaches the right people. In a nutshell, you need to communicate in a way your job gets done in the most simple and quick manner.There is also a 4th skill to know and master – systems design – but that’s something only for more experienced job-seekers applying for senior software engineering positions.
Approach based on time left for the interview.
Before giving you the scoop on the hot topics in interviews and their associated questions, let us discuss our battle strategy to tackle it. It’s usually beneficial to prepare for interviews according to the time you have left before it. Makes sense, right? Well, let’s jump right in!
1-3 months to interview:
Oh boy, less than 3 months to showdown. Since we can never actually know which data structure or algorithm might be asked, here it is a good idea to get a working knowledge of as many topics as you possibly can. What this means is, we are going for a ‘jack of all trades’ approach rather than ‘master of one’.
if ( !agreeWithThis )
For the people who disagree with this point of view, let me try and convince you – suppose you spend the bulk of your prep time and ace one of the most asked topics: arrays. Now imagine you show up to the interview and the interviewer asks you a question from graphs – bonkers, right? However, if you have the basics down, maybe you can somehow work on a solution, which will be much better than thinking about X-Y axes on hearing “graphs”.
Convinced? Great! You should go for a Breadth-First approach on topics and just prepare enough questions from each topic to get a hang of the concept. Do not spend a lot of time on any one specific topic. What this means can differ from person to person. One might take 8-10 questions to get the topic straight, while another might do it in 4-5. What’s important is that you do not cross the 10-12 question threshold, or else you’ll be eating into the time of another topic.
Resources to definitely follow: Cracking the Coding Interview by Gayle McDowell
3-6 months to interview
This can be one of the most ideal timelines. You have enough time to get a good grasp on the topics while you’re still not so far along from the interview that you’re not motivated enough. You should follow the breadth-first approach described above and spend more time on topics to get a good grasp on them.
Simultaneously, try building small projects alongside. My recommendation is that you start with your web portfolio. Besides the benefits of having a personal portfolio, it will also give you an idea of how to build and publish a website on your own. You can add other projects in here as well.
A good way to get hands-on experience with cool projects is to participate in Hackathons. They are short tech events in which teams of developers get together to build a solution to a proposed problem. They are a great way of learning how to collaborate, working well in a team, and to upskill yourself. You can find all Hackathons going on at HackerEarth here.
Would you like to get updates once a month on our latest articles? We won’t spam, we promise. Subscribe now to The HackerEarth Blog!
6+ months to interview
Boy, oh, boy, are you gonna nail this interview or what? Since you have a lot of time to prepare, we suggest that after getting comfortable by doing the above things, you can start contributing to open source projects on GitHub. You can Google “good first issue” to start with. Repository maintainers put this tag on issues to make it easier for freshers to start contributing to open source. Also, give another go at the questions. You will refresh your memory and might even come up with a better or more concise way of solving them.
Without further ado, let me present to you the most commonly asked topics in competitive interviews. Each topic will have one tutorial article and a few questions associated with it. You can directly attempt the questions if you are comfortable with the topic. The questions have been chosen to help you solidify your understanding of the topic and also serve as a test. Ideally try and maintain a healthy ratio of 3-6-1 of easy, medium and hard problems.
- Binary Search:
- Hash Maps and Tables
- Linked List
- Dynamic Programming (DP)
Some tips on interviewing w/ special note on remote interviewing:
- Go to the company’s careers page and read up on their job description. They do tell you everything that you need to know about that role.
- Create mock interviews by yourself by pairing up with friends who are also interviewing for a similar job. Try to simulate real interviews as much as possible by interviewing over a video call and perhaps use a shared doc to write code. Give each other pointers on what went well and what did not.
- When applying, make sure that you don’t put all your eggs in one basket. Apply to a whole range of companies and job roles to significantly increase your chances of receiving an offer.
- Most companies have a distinct pattern in which they take interviews. For example, Amazon conducts 5-6 rounds of interviews and they like to emphasize a lot on their leadership principles (LPs). In this case, it would be prudent to be well prepared and research beforehand about the same, so you know exactly what to expect.
Last but not the least, go communicate with people and read about their past experiences of interviewing at the companies that you are now applying for. And remember to give back and share your experiences too, so that that might help someone in need!
So, all the very best, and may the odds be ever in your favor!