My interview experience at Cars24, Role: ReactJS Developer
Table of contents
No headings in the article.
Hi Everyone,
The interview was taken by a third Party “Interview Vector”. The interviewer was quite friendly and had good domain knowledge.
Position: ReactJS Developer
Round 1(JavaScript and Problem Solving, time duration — 60mins ) :
1. Map, Filter Explanation: The interviewer initiated the discussion by exploring the understanding of map and filter functions in JavaScript, emphasizing their usage and utility in data manipulation tasks.
2. Build a Counter Function Creator:
Create a function that takes an integer n as input and returns another function called counter. This counter function should initially return the input n and then return 1 more than the previous value every subsequent time it is called (n, n + 1, n + 2, etc).
Your implementation should use ESM (ECMAScript Modules) for importing and exporting functions and variables. You will be required to work with the function createCounter in the index.js file.
Examples const counter = createCounter(5);
console.log(counter()); // Output: 5
console.log(counter()); // Output: 6
console.log(counter()); // Output: 7
Example 2: const counter = createCounter(-3);
console.log(counter()); // Output: -3
console.log(counter()); // Output: -2
3. Closures: Understanding of closures in JavaScript, emphasizing their role and practical application in maintaining lexical scopes.
4. Promises and Async/Await: The concept of promises, distinguishing between promises and async/await syntax. Additionally, the discussion touched upon callback functions and the potential issues associated with callback hell.
5. Shadowing and Output-Based Questions: He presented some scenarios involving variable shadowing and was tasked with predicting the output based on the provided code snippets. (2–3 questions)
6. Let, const and var + output based questions on these(3–4 question were asked using concepts of closures)
7. Temporal Dead Zone: The interviewer concluded the round by discussing the Temporal Dead Zone phenomenon in JavaScript, highlighting its significance in variable declaration and initialization.
Overall, the JavaScript round aimed to assess proficiency in core JavaScript concepts, problem-solving abilities, and familiarity with modern JavaScript features.
It will surely help you for your upcoming JS interviews.
All the best for your interviews ☺️