DEV Community

Sujal Gupta
Sujal Gupta

Posted on

Tata 1mg SDE1 - Frontend Engineer Interview Experience

Hi, in this post I am sharing my interview experience for the role of SDE-1 Frontend Engineer at Tata 1mg. This interview happened a while back in May 2024 and this blog was still in my draft. So, I finally decided to share my experience by completing this blog.

This is my first time writing a detailed blog post. I tried to cut out too many details and keep the relevant parts. Please share your feedback in comments.

So let's start,
As for the application process, I applied to the job through their career portal without any referral.

Tip : It is more sensible to apply at the job as soon as possible directly instead of waiting for a referal. It often happens that by the time you hear from the other person for referal, the job post has already expired.

I got a call from the HR one week after I applied and she scheduled my first round of interview. My first interview round was scheduled for two days later. I was told that the first interview round will happen about Data Structure and Algorithms.

Since I was already preparing for interview and practicing Leetcode, I was confident in that part.

First Round

: This started with a brief introduction from both ends.
The first question was to implement a function to check if a string is palindrome.

While, this was not a hard question or involved any usage of complex data structures, I asked the interviewer if I could implement the same in C++ as I am much faster in writing C++ code as compared to JavaScript, since I was solving LeetCode problem in C++ for a very long time.
The interviewer suggested that the this is a frontend interview so I should be using JavaScript instead.

Tip: Practicing basic DSA Questions in JavaScript might help you in some cases as some interviewers expect you to code in only JavaScript. Remembering how to use common data structure like map and set would help.

Okay, now back to the questions.
I then started to implement it in JavaScript.

Q. The first problem was to implement a function to check if a given string is palindrome. Even though I knew how to solve it by heart. A silly mistake in the code outside the function cause some error which took us(yes the interviewer too) a while to find out. I found the error and fixed it and it worked.

Then we started discussing some basic JavaScript questions

Q. Difference between let and const.
Ans. I told him the basic difference and he was satisfied.

Q. What are primitives and non-primitive types in JavaScript?
Ans. I didn't know about the term back then, but the answer was to mention all the basic types like boolean, number, undefined, null etc. For more Read here.

Q. Why mutating const is allowed but not reassignment.
Ans: I wasn't sure about the answer and explained through code examples that reassignment is not allowed but I couldn't explain why this happens.
The interviewer told me that the answer was somewhat related to previous question about primitives.

To learn more about this you can refer this excellent interactive blog by @joshwcomeau The “const” Deception

Q. What is hoisting in JavaScript?
Ans. Preety straight forward. I told him the answer and then we moved to next question.

Q. What is TypeScript and its features?
Ans. I told him about interfaces and types, and other basic features like being able to catch error before hand which could only be identified when you run code in case of plain JavaScript. He was satisfied with the answer.

Second Round

Q. Implement Debouncing
Ans. I have only heard about debouncing back then and had some idea in mind. So, using that idea I started writing some code. I started writing thing based on my rough understanding of debouncing. I wrote a loop which would run for a long time to showcase a heavy/long operation which we then would need to somehow cancel when a certain event keeps firing within a certain delay.

The interviewer saw my intuition and pointed that he understood what I am trying to achieve but I was missing some key logic.

Q. A slight variation of 2-sum problem on Leetcode.
Arr = [1, 5, 2, 6, 8, 9, 10], target = 7
O/P: [1, 6], [5, 2], [2, 5], [6, 1]

Ans. I was able to implement it correctly.

Q. Polyfill of Promise.all
Ans. I was unaware of this, so couldn't implment it.

Q. What is prototypal inheritance?
Ans. I answered it correctly and we moved on to the next question.

Q. How does useMemo works under the hood?
Ans. I told the interviewer that useMemo does memoization by saving the calculation in some data structure so we can use it directly when needed without doing the calculation again. But the interviewer was expecting some indepth answer which I was not aware of at that time.

Overall, my second round went bad and I got a rejection mail after a few days.

Learnings

I have now understood that it is now very common and bare minimum for frontend developers to learn some optimization techniques and also practice about commonly asked interview questions. DSA questions asked to frontend devs is usually easy.

I suggest using Akshay Saini's playlist for preparing for frontend interviews.

After this interview, I learned many optimization techniques and commonly asked interview questions and formed a good understanding of them. I also apply whatever I learned from those material. I made me a better developer overall.

Hot sauce if you're wrong - web dev trivia for staff engineers

Hot sauce if you're wrong · web dev trivia for staff engineers (Chris vs Jeremy, Leet Heat S1.E4)

  • Shipping Fast: Test your knowledge of deployment strategies and techniques
  • Authentication: Prove you know your OAuth from your JWT
  • CSS: Demonstrate your styling expertise under pressure
  • Acronyms: Decode the alphabet soup of web development
  • Accessibility: Show your commitment to building for everyone

Contestants must answer rapid-fire questions across the full stack of modern web development. Get it right, earn points. Get it wrong? The spice level goes up!

Watch Video 🌶️🔥

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

If you found this article helpful, a little ❤️ or a friendly comment would be much appreciated!

Got it