i
Head Digital Works
Filter interviews by
I applied via LinkedIn and was interviewed in Nov 2024. There was 1 interview round.
Fallback in lazy loading is important for optimizing API calls to ensure a smooth user experience.
Implementing a loading spinner or placeholder while content is being loaded asynchronously
Using a default value or cached data if the API call fails
Implementing error handling to gracefully handle any issues with the API call
First round was a coding question with html, css, javascript to create 5 clickable boxes, change it's colors on click and update count
I applied via Naukri.com and was interviewed in May 2024. There were 2 interview rounds.
Medium level DSA question in JS
I applied via LinkedIn and was interviewed in Dec 2022. There were 3 interview rounds.
React lifecycle in functional components
useEffect hook replaces lifecycle methods
useEffect runs after every render by default
useEffect can be controlled by dependencies array
useEffect cleanup function can be used to clean up effects
useLayoutEffect hook runs synchronously after DOM mutations
Return numbers in array equal to sum
I was interviewed in Sep 2021.
Round duration - 45 Minutes
Round difficulty - Easy
Given an array or list ARR
consisting of N
integers, your task is to identify all distinct triplets within the array that sum up to a specified number K
.
A t...
The task is to identify all distinct triplets within an array that sum up to a specified number.
Iterate through the array and use nested loops to find all possible triplets.
Check if the sum of the triplet equals the specified number.
Print the valid triplets or return -1 if no such triplet exists.
Given a sorted array A consisting of N integers, your task is to find the magic index in the given array, where the magic index is defined as an index i such that A[i] = i...
Find the magic index in a sorted array where A[i] = i.
Iterate through the array and check if A[i] = i for each index i.
Since the array is sorted, you can optimize the search using binary search.
Return the index if found, else return -1.
Round duration - 50 Minutes
Round difficulty - Hard
You are provided with a sorted dictionary (by lexical order) in an alien language. Your task is to determine the character order of the alien language from this dictiona...
Given a sorted alien dictionary in an array of strings, determine the character order of the alien language.
Iterate through the words in the dictionary to build a graph of character dependencies.
Perform a topological sort on the graph to determine the character order.
Return the character array representing the order of characters in the alien language.
Given a positive integer N
, your goal is to find all the Jumping Numbers that are smaller than or equal to N
.
A Jumping Number is one where every adjacent digit has an a...
Find all Jumping Numbers smaller than or equal to a given positive integer N.
Iterate through numbers from 0 to N and check if each number is a Jumping Number.
For each number, check if the absolute difference between adjacent digits is 1.
Include all single-digit numbers as Jumping Numbers.
Output the list of Jumping Numbers that are smaller than or equal to N.
Given an integer N
representing the number of strings in an array Arr
composed of lowercase English alphabets, determine a string S
of length N
such that it can be used t...
Given an array of strings, find the lexicographically smallest string that can be used as a prefix to minimize the total cost of deleting prefixes from the strings.
Iterate through the array to find the common prefix among all strings
Choose the lexicographically smallest common prefix
Delete the common prefix from each string in the array to minimize the total cost
Round duration - 20 Minutes
Round difficulty - Easy
Tip 1 : Be consistent, practice regularly whatever you read/study.
Tip 2 : Apply what you learn through code.
Tip 1 : Have some projects on your resume.
Tip 2 : If you have an internship or training explain it in a proper way like what are the techniques you learned during your training.
I applied via Naukri.com and was interviewed in Nov 2021. There was 1 interview round.
I was interviewed before Jan 2021.
Round duration - 60 minutes
Round difficulty - Easy
Two coding questions were given in the first round to be solved in 60 minutes.
Given an array A
containing 'N' integers and an integer m
, rearrange the elements of the array such that the differences between the array elements and m
are sor...
Rearrange array elements based on their differences from a given integer.
Calculate the differences between each element and the given integer.
Sort the elements based on their differences while maintaining the original order for elements with the same difference.
Implement a function to rearrange the array elements as per the given criteria.
Given an arbitrary binary tree, a node of the tree, and an integer 'K', find all nodes that are at a distance K from the specified node, and return a list of th...
The task is to find all nodes in a binary tree that are at a distance K from a given node.
Traverse the binary tree to find the given node
From the given node, perform a depth-first search to find all nodes at distance K
Use a list to store the values of the nodes at distance K
Return the list of values in any order
Round duration - 60 minutes
Round difficulty - Easy
This was a technical round with questions based on DSA, DBMS, Computer Networking and project based questions.
Ninja is tasked with printing a triangle pattern based on a given number 'N' for any test case.
N = 4
1
232
34545
4567654
The pat...
Print a triangle pattern of numbers based on a given number 'N'.
Iterate through each row and print the numbers accordingly
Use spaces to center-align the numbers in each row
Increment the numbers in each row as per the pattern
Web server serves static content over HTTP, while application server runs dynamic content and business logic.
Web server handles HTTP requests and responses, serving static content like HTML, images, and CSS.
Application server executes business logic, runs dynamic content, and interacts with databases.
Web server examples include Apache, Nginx, while application server examples include Tomcat, JBoss.
Web server focuses on...
The internet is a global network of interconnected computers that communicate using standardized protocols.
The internet is made up of a vast number of interconnected networks of computers.
Data is transmitted over the internet using protocols such as TCP/IP.
Websites are hosted on servers connected to the internet, and users access them using web browsers.
Internet Service Providers (ISPs) provide access to the internet f...
SQL query to find the nth highest salary
Use the 'SELECT DISTINCT' statement to get unique salary values
Order the salaries in descending order using 'ORDER BY' clause
Use 'LIMIT' and 'OFFSET' to get the nth highest salary
Round duration - 30 minutes
Round difficulty - Easy
Typical HR round with behavioral problems.
Tip 1 : Must do Previously asked Interview as well as Online Test Questions.
Tip 2 : Go through all the previous interview experiences from Codestudio and Leetcode.
Tip 3 : Do at-least 2 good projects and you must know every bit of them.
Tip 1 : Have at-least 2 good projects explained in short with all important points covered.
Tip 2 : Every skill must be mentioned.
Tip 3 : Focus on skills, projects and experiences more.
I was interviewed before Feb 2021.
Round duration - 90 minutes
Round difficulty - Medium
Questions on aptitude, English, logical reasoning, C/C++ and 5 coding ques. (only pseudo code).
Bob and his wife are in the famous 'Arcade' mall in the city of Berland. This mall has a unique way of moving between shops using trampolines. Each shop is laid out in a st...
Find the minimum number of trampoline jumps Bob needs to make to reach the final shop, or return -1 if it's impossible.
Use Breadth First Search (BFS) algorithm to find the minimum number of jumps required.
Keep track of the visited shops to avoid revisiting them.
If a shop has an Arr value of 0, it is impossible to reach the final shop.
Return -1 if the final shop cannot be reached.
Given two strings, S
and X
, your task is to find the smallest substring in S
that contains all the characters present in X
.
S = "abdd", X = "bd"
Find the smallest substring in S that contains all characters in X.
Use a sliding window approach to find the smallest window in S containing all characters of X.
Maintain a hashmap to keep track of characters in X and their frequencies in the current window.
Slide the window to the right, updating the hashmap and shrinking the window until all characters in X are present.
Return the smallest window found.
Example: S = 'abd
You need to determine all possible paths for a rat starting at position (0, 0) in a square maze to reach its destination at (N-1, N-1). The maze is represented as an N*N ma...
Find all possible paths for a rat in a maze from start to destination.
Use backtracking to explore all possible paths in the maze.
Keep track of visited cells to avoid revisiting them.
Return paths in alphabetical order as a list of strings.
Round duration - 60 minutes
Round difficulty - Easy
Questions based on OOPS were asked in this round.
A virtual function is a function in a base class that is declared using the keyword 'virtual' and can be overridden by a function with the same signature in a derived class.
Virtual functions allow for dynamic polymorphism in C++
They are used in inheritance to achieve runtime polymorphism
Virtual functions are declared in a base class and can be overridden in derived classes
They are called based on the type of object bei...
Types of polymorphism in OOP include compile-time (method overloading) and runtime (method overriding) polymorphism.
Compile-time polymorphism is achieved through method overloading, where multiple methods have the same name but different parameters.
Runtime polymorphism is achieved through method overriding, where a subclass provides a specific implementation of a method that is already defined in its superclass.
Polymor...
Deep copy creates a new object and recursively copies all nested objects, while shallow copy creates a new object and copies only the references to nested objects.
Deep copy creates a new object and copies all nested objects, while shallow copy creates a new object and copies only the references to nested objects.
In deep copy, changes made to the original object do not affect the copied object, while in shallow copy, ch...
Round duration - 30 minutes
Round difficulty - Easy
HR round with typical behavioral problems.
Tip 1 : Must do Previously asked Interview as well as Online Test Questions.
Tip 2 : Go through all the previous interview experiences from Codestudio and Leetcode.
Tip 3 : Do at-least 2 good projects and you must know every bit of them.
Tip 1 : Have at-least 2 good projects explained in short with all important points covered.
Tip 2 : Every skill must be mentioned.
Tip 3 : Focus on skills, projects and experiences more.
Find the subset of an array with the largest sum of continuous positive numbers.
Iterate through the array and keep track of the current sum and the maximum sum seen so far.
If the current element is positive, add it to the current sum. If it is negative, reset the current sum to 0.
Also keep track of the start and end indices of the maximum sum subset.
Return the subset using the start and end indices.
Find smallest substring in s1 containing all characters of s2.
Create a hash table of characters in s2
Use sliding window technique to find smallest substring in s1
Check if all characters in s2 are present in the substring
Update the smallest substring if a smaller one is found
Algorithm to reverse a linked list
Create a new empty linked list
Traverse the original linked list and insert each node at the beginning of the new list
Return the new list
Lazy loading is a technique used to defer the loading of non-critical resources until they are needed.
Advantages: faster initial page load, reduced bandwidth usage, improved user experience
Disadvantages: increased complexity, potential for slower subsequent page loads, difficulty with SEO
Examples: images, videos, and other media files can be loaded only when they are visible on the screen
Ajax is a technique for creating fast and dynamic web pages. AngularJS is a framework for building dynamic web applications, while jQuery is a library for simplifying HTML DOM traversal and manipulation.
Ajax stands for Asynchronous JavaScript and XML
It allows web pages to be updated asynchronously by exchanging data with a web server behind the scenes
AngularJS is a JavaScript framework that extends HTML with new attrib...
A traffic light system controls the flow of traffic at intersections.
The system consists of three lights: red, yellow, and green.
Each light has a specific duration for which it stays on.
The system also includes sensors to detect the presence of vehicles and pedestrians.
The duration of each light can be adjusted based on traffic patterns.
The system can be connected to a central control system for remote monitoring and m
based on 1 interview
Interview experience
Software Engineer
25
salaries
| ₹0 L/yr - ₹0 L/yr |
Software Development Engineer II
24
salaries
| ₹0 L/yr - ₹0 L/yr |
Senior Software Engineer
20
salaries
| ₹0 L/yr - ₹0 L/yr |
Module Lead
19
salaries
| ₹0 L/yr - ₹0 L/yr |
Associate Product Manager
15
salaries
| ₹0 L/yr - ₹0 L/yr |
Info Edge
JustDial
Indiamart Intermesh
MakeMyTrip