Filter interviews by
To delete a node in a linked list, we need to find the node and update the pointers of its previous and next nodes.
Find the node to be deleted by traversing the linked list
Update the pointers of the previous and next nodes to skip the node to be deleted
Free the memory occupied by the node to be deleted
I appeared for an interview before Jan 2021.
Round duration - 60 minutes
Round difficulty - Easy
I had one interview for approx. an hour, it includes both Technical and HR round, well mostly technical. Interview starts with tell me something about yourself. Asked in detailed about algorithms/web based projects mentioned in CV, make sure that whatever you have written you have complete knowledge about it. Asked to code few basic algorithms questions. Do mention about small project if you have done related to web development.
If interviewer says if you want to ask any question, its always better to ask one or two question.
A Binary Search Tree (BST) is a data structure where each node has at most two children, with the left child being less than the parent and the right child being greater.
Nodes in a BST are arranged in a hierarchical order where the left subtree of a node contains only nodes with keys less than the node's key, and the right subtree contains only nodes with keys greater than the node's key.
BST allows for efficient search...
Given the root node of a binary search tree and a positive integer, you need to insert a new node with the given value into the BST so that the resulting tree maintains the pr...
Insert a new node with a given value into a binary search tree while maintaining the properties of a BST.
Traverse the BST starting from the root node and compare the value to be inserted with each node's value to determine the correct position for insertion.
Insert the new node as a leaf node in the appropriate position to maintain the BST properties.
Ensure that the resulting tree is a valid binary search tree by follow...
You are provided with a Binary Search Tree (BST) containing 'N' nodes with integer data. Your task is to remove a given node from this BST.
A BST is a ...
Delete a given node from a Binary Search Tree (BST) and return the inorder traversal of the modified BST.
Traverse the BST to find the node to be deleted.
Handle different cases like node with no children, one child, or two children.
Update the pointers of the parent node and child nodes accordingly.
Perform inorder traversal after deletion to get the modified BST.
Given a linked list where each node has two pointers: one pointing to the next node and another which can point randomly to any node in the list or ...
Yes, the cloning of a linked list with random pointer can be accomplished without utilizing extra space.
Use a hashmap to store the mapping between original nodes and their corresponding cloned nodes.
Iterate through the original linked list to create the cloned nodes and update the hashmap.
Iterate through the original linked list again to set the next and random pointers of the cloned nodes using the hashmap.
Time comple...
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 : Must verify your CV from your seniors/batchmates.
Tip 2 : Include all the projects, intern work or hall activities or anything you have done on your own which is related to or interest of company. If you know any back-end/front-end (javascript, php, mysql etc) language do mention. I think the cv shortlist was completely based on previous work and technical skills related to Web Development/Design mentioned in the CV.
Tip 3 : Focus on skills, projects and experiences more.
I appeared for an interview before Jan 2021.
Round duration - 90 minutes
Round difficulty - Easy
The test was of moderate level, the coding question was easy if all the boundary questions were properly considered.
You are given a positive integer n
. Your task is to identify the largest prime factor of this given positive integer.
If there is no prime factor for a given intege...
Identify the largest prime factor of a given positive integer.
Iterate from 2 to sqrt(n) to find prime factors
Check if each factor is prime and update largest prime factor
If no prime factor found, output -1
You are provided with an integer array ARR
of length 'N'. Your objective is to determine the first missing positive integer using linear time and constant space. T...
Find the smallest positive integer missing from an array of integers.
Iterate through the array and mark positive integers as visited using index as a reference.
After marking, iterate again to find the first unmarked index which represents the missing positive integer.
Handle edge cases like duplicates and negative numbers appropriately.
Example: For input [3, 4, -1, 1], the output should be 2.
Round duration - 60 minutes
Round difficulty - Easy
The interviewer was friendly and he was interested in the implementation first and then the code.
Tips: Be thorough with various implementations and why they are in practice. Try to know the logic behind each implementation.
You are provided with a binary array, i.e., an array containing only 0s and 1s. Your task is to sort this binary array and return it after sorting.
The fir...
Yes, the binary array can be sorted in linear time and constant space using a single traversal.
Use two pointers approach to swap 0s to the left and 1s to the right.
Maintain two pointers, one for 0s and one for 1s, and iterate through the array once.
Example: Input array [1, 0, 1, 0, 1] will be sorted to [0, 0, 1, 1, 1] in a single traversal.
Polymorphism in OOP allows objects of different classes to be treated as objects of a common superclass.
Polymorphism allows for flexibility and reusability in code.
It enables a single interface to be used for different data types.
Examples include method overriding and method overloading.
Operator overloading is the ability to redefine the behavior of operators for user-defined data types.
Allows operators to be used with custom data types
Can define custom behavior for operators like +, -, *, etc.
Helps make code more readable and intuitive
Example: Overloading the + operator for a custom Vector class to add two vectors
Method overloading is having multiple methods in the same class with the same name but different parameters. Method overriding is having a method in a subclass with the same name and parameters as a method in its superclass.
Method overloading involves multiple methods with the same name but different parameters.
Method overriding involves a subclass redefining a method from its superclass with the same name and paramete...
Round duration - 45 minutes
Round difficulty - Easy
The interviewer was looking for a person interested in problem solving. He was looking forward for loud thinking.
Tips: If you don't know any answer, don't lose your cool. It is never necessary to answer all the questions in an interview. Be confident and think loud, so that if you are going the wrong way, the interviewer can assist you.
Round duration - 30 minutes
Round difficulty - Easy
This was the last round and just for formality. The interviewers were looking for a person who would fit in their working culture.
Tips: Be confident and always have a smile on your face. If you are selected for the HR interview, then there is a 90% chance that you would be selected.
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.
Times Internet interview questions for designations
Find the second largest prime number and its index from an array of positive integers.
Iterate through the array and check if each number is prime
Store the largest and second largest prime numbers found so far
Also store their indices
Return the second largest prime number and its index
Find the first missing positive number in an array of positive and negative integers.
Sort the array in ascending order
Iterate through the sorted array and find the first positive number that is missing
If no positive number is missing, return the next positive number after the largest positive number in the array
The data structure to program a jigsaw puzzle program would be a graph.
Use a graph data structure to represent the puzzle pieces and their connections.
Each puzzle piece can be represented as a node in the graph.
Edges between nodes represent the connections between puzzle pieces.
To solve the puzzle, use graph traversal algorithms like depth-first search or breadth-first search.
Apply puzzle-solving strategies like findin
Times Internet Limited (TIL) is a digital products company that operates various online platforms and services.
TIL is a subsidiary of Bennett Coleman & Co. Ltd (BCCL), which is India's largest media conglomerate.
TIL operates popular websites and apps like Times of India, Economic Times, Gaana, MX Player, and Cricbuzz.
TIL focuses on digital content, e-commerce, and technology solutions.
TIL has a diverse portfolio of...
I transitioned to software development due to my passion for coding and problem-solving.
I discovered my interest in coding during my civil engineering studies
I took online courses and attended coding bootcamps to learn software development skills
I completed projects and internships in software development to gain practical experience
I enjoy the creativity and problem-solving aspects of software development
The average speed can be calculated by taking the harmonic mean of the two speeds.
To calculate the harmonic mean, divide the sum of the speeds by the reciprocal of the sum of their reciprocals.
In this case, the harmonic mean can be calculated as 2/(1/20 + 1/30) = 24 km/h.
The minimum number of steps to find the defective ball is 2.
Divide the 8 balls into 3 groups of 3, 3, and 2 balls.
Compare the weights of the two groups of 3 balls.
If one group is heavier, divide it into 2 balls and compare their weights.
If the two balls have different weights, the heavier ball is the defective one.
If the two balls have the same weight, the remaining ball in the first group of 3 is the defective one.
Polymorphism is the ability of an object to take on many forms. It allows objects of different classes to be treated as the same type.
Polymorphism is achieved through method overriding and method overloading.
Method overriding allows a subclass to provide a specific implementation of a method that is already defined in its superclass.
Method overloading allows multiple methods with the same name but different parameters ...
Operator overloading is the ability to redefine operators for custom classes.
Allows operators to be used with custom classes
Example: '+' operator can be used to concatenate strings
Can improve readability and simplify code
Method overloading is having multiple methods with the same name but different parameters. Method overriding is having a method in a subclass with the same name, return type, and parameters as a method in its superclass.
Method overloading is achieved within the same class.
Method overriding occurs in a subclass that inherits from a superclass.
Method overloading is determined at compile-time based on the number, type, an...
Get interview-ready with Top Times Internet Interview Questions
Top trending discussions
I applied via Job Portal and was interviewed before Oct 2020. There were 4 interview rounds.
posted on 21 Dec 2020
I appeared for an interview before Sep 2020.
Round duration - 90 minutes
Round difficulty - Medium
Online test which can be attempted anytime between 22 May 2020, 06:00 AM and 25 May 2020, 01:00 AM
Given a postfix expression, your task is to evaluate the expression. The operator will appear in the expression after the operands. The output for each expr...
Evaluate postfix expressions by applying operators to operands in a given order.
Iterate through the postfix expression and push operands onto a stack
When an operator is encountered, pop the required number of operands from the stack, apply the operator, and push the result back onto the stack
Continue until the entire expression is evaluated and the final result is left on the stack
You are given D
dice, each having F
faces numbered from 1 to F
. The task is to determine the number of possible ways to roll all the dice such that the sum of the face-up num...
The task is to determine the number of possible ways to roll all the dice such that the sum of the face-up numbers equals the given 'target' sum.
Use dynamic programming to solve the problem efficiently.
Create a 2D array to store the number of ways to achieve each sum with different number of dice.
Iterate through the dice and sum possibilities to fill up the array.
Return the result modulo 10^9 + 7.
Optimize the solution ...
Round duration - 60 minutes
Round difficulty - Medium
June 25 2020
Timing: 12:00 pm to 1:00 pm
This round was completely devoted to coding. I was asked to introduce myself and then 2 coding questions were asked.
Given a sorted array ARR
consisting of N
integers and an integer X
, find the first and last positions of occurrence of X
in the array.
Find the first and last positions of an element in a sorted array efficiently.
Use binary search to find the first occurrence of X in the array.
Use binary search to find the last occurrence of X in the array.
Handle cases where X is not present or present only once.
Return the first and last positions as 0-based indices.
You are given an N x N maze where some cells have doors, and you have a key that can be used only once to open a door. Determine if there exists a path from t...
Determine if there exists a path from the top-left cell to the bottom-right cell of a maze with N doors and 1 key.
Use depth-first search (DFS) or breadth-first search (BFS) to explore possible paths through the maze.
Keep track of the cells visited and use the key only once to open doors.
Check if the bottom-right cell is reachable after traversing the maze.
Handle edge cases such as the top-left and bottom-right cells ha...
Round duration - 60 minutes
Round difficulty - Medium
9th July 2020
6:30PM to 7:30PM
Round duration - 60 minutes
Round difficulty - Easy
23-July 2020
4:00 PM to 5:00 PM
Coding questions + Several questions on computer fundamentals and networking were asked in a rapid-fire manner.
Given the stock prices for 'N' days, your goal is to determine the maximum profit that can be achieved. You can buy and sell the stocks any number of times but can onl...
The goal is to determine the maximum profit that can be achieved by buying and selling stocks on different days.
Iterate through the stock prices and buy on the days when the price is lower than the next day's price, and sell on the days when the price is higher than the next day's price.
Calculate the profit by summing up the differences between buying and selling prices.
Repeat the process for each test case and output
Round duration - 60 minutes
Round difficulty - Medium
6- Aug 2020
3:00 PM to 4:00 PM
Resceduled to: @5:30 PM
Projects, Fundamentals check, Behavioral, Coding
Given a directed graph with a specified number of vertices V
and edges E
, your task is to calculate the total number of distinct paths from a given source node S
to all ot...
Calculate total number of distinct paths from a given source node to all other nodes in a directed graph.
Use dynamic programming to keep track of the number of paths from the source node to each node.
Consider the modulo operation to handle large numbers efficiently.
Start by initializing the number of paths from the source node to itself as 1.
Iterate through all edges and update the number of paths for each destination ...
Tip 1 : Be confident while answering questions
Tip 2 : Make the interview conversational and Always keep a smiling face
Tip 3 : Ask something at the end of the interview which shows your interest in the company
Tip 4 : Prepare projects on the skills mentioned in the resume
Tip 1 : Mention projects and internships.
Tip 2 : Keep your resume short and crisp.
I appeared for an interview in Sep 2020.
Round duration - 90 Minutes
Round difficulty - Easy
Two coding questions were asked and 90 minutes of time was allotted to solve both the problems
Given an array of integers ARR
of length N
and an integer Target
, your task is to return all pairs of elements such that they add up to the Target
.
The first line ...
Given an array of integers and a target, find all pairs of elements that add up to the target.
Iterate through the array and for each element, check if the target minus the element exists in a hash set.
If it exists, add the pair to the result. If not, add the element to the hash set.
Handle cases where the same element is used twice to form a pair.
Return (-1, -1) if no pair is found.
Given a binary matrix of size N * M
where each element is either 0 or 1, find the shortest path from a source cell to a destination cell, consisting only...
Find the shortest path in a binary matrix from a source cell to a destination cell consisting only of 1s.
Use Breadth First Search (BFS) algorithm to find the shortest path in the binary matrix.
Keep track of visited cells to avoid revisiting them.
Update the path length as you traverse the matrix.
Return -1 if no valid path exists from source to destination.
Round duration - 60 Minutes
Round difficulty - Medium
The duration was approx 1 hour. The interview was taken by a young SDE-2.
You are given a string 'S' of length 'N'. Your task is to find the frequency of each character from 'a' to 'z' in the string.
S : abcdg
1...
The task is to find the frequency of each character from 'a' to 'z' in a given string.
Create an array of size 26 to store the frequency of each character from 'a' to 'z'.
Iterate through the string and increment the count of the corresponding character in the array.
Print the array of frequencies as the output.
Given a matrix MAT
of size N * M
, where each cell is either on fire or safe, determine if a person can reach an escape cell without being burnt. The person starts from ...
Determine if a person can reach an escape cell without encountering fire in a matrix.
Check if the person can reach an escape cell without encountering fire by simulating the movement of the person and fire spread.
If the person can reach an escape cell, return the time taken; otherwise, return -1.
Consider the constraints and edge cases while implementing the solution.
Round duration - 60 Minutes
Round difficulty - Hard
The interviewer introduced himself and asked me to introduce myself.
I told him about the different projects that I had done and the work in the previous company.
I had worked on AWS(Amazon Web Services) so he asked me all the AWS services that I had worked with and to explain one of them.
I explained about the working of ECS(Elastic Container Service).
After this, he moved to the coding questions.
Given a binary matrix of size N*M, find the maximum distance 'di' for every 0-cell to its nearest 1-cell, where the distance is measured using Manhattan distance. Th...
Find the maximum Manhattan distance from a 0-cell to its nearest 1-cell in a binary matrix.
Iterate through the matrix to find all 0-cells and calculate their distances to nearest 1-cells using Manhattan distance formula
Keep track of the maximum distance found so far and update it if a larger distance is encountered
Return the maximum distance as the final result
You are provided with an array containing 'N' non-negative integers, along with two other non-negative integers 'K' and 'M'. Your task is to identify ...
Find a pair of indices in an array with given difference and distance constraints.
Iterate through the array and check all possible pairs of indices to satisfy the conditions
Use nested loops to compare each pair of indices and their corresponding elements
Return 'valid' if a pair of indices is found that meets the conditions, otherwise return 'invalid'
Round duration - 60 Minutes
Round difficulty - Medium
The interviewer was a very senior person with at least 10-15 years of experience. He introduced himself and asked me to tell him about myself. (Leadership principle questions followed)
Determine whether an arbitrary binary tree is special. A binary tree is called special if every node in this tree has either zero or two children.
...
Determine if a binary tree is special if every node has zero or two children.
Traverse the tree and check if each node has either 0 or 2 children.
Use a recursive approach to check children of each node.
If any node has only one child, return false immediately.
Example: For the given input, the output should be true.
Round duration - 60 Minutes
Round difficulty - Medium
The interview started with introductions and some Leadership principle questions. The interviewer was again a senior person with at least 10-15 years of experience.
I was asked to explain some AWS services.
He asked me to tell about a time when I had a tight deadline and how I worked during it.
He asked me about a time when I took initiative and came up with something new which helped the entire team.
I had prepared well for the LP questions and was able to answer everything.
After this, we move on to coding questions.
Determine if a given word 'W' is present in the sentence 'S' as a complete word. The word should not merely be a substring of another word.
The first line contains an in...
Check if a given word is present in a sentence as a complete word.
Split the sentence into words using spaces as delimiter.
Check if the given word matches any of the words in the sentence.
Ensure that the word is not just a substring of another word in the sentence.
Design a data structure for a Least Recently Used (LRU) cache that supports the following operations:
1. get(key)
- Return the value of the key if it exists in the cache; otherw...
Design a Least Recently Used (LRU) cache data structure that supports get and put operations with capacity constraint.
Use a combination of hashmap and doubly linked list to implement the LRU cache.
Keep track of the least recently used item and update it accordingly.
Ensure to handle cache capacity by evicting the least recently used item when the cache is full.
Tip 1 : Start with the basics if you have lost touch with competitive coding. Don't directly jump to interview questions.
Tip 2 : Create a timetable and set goals. Keep aside 3-4 hours for studying. Consistency is the key.
Tip 3 : Focus on medium and hard questions. Solving a lot of easy questions doesn't help.
Tip 1 : You should have good projects to showcase.
Tip 2 : Keep it clean and simple.
I appeared for an interview in Aug 2017.
Merge Sort is a divide and conquer algorithm that sorts an array by dividing it into two halves, sorting them separately, and then merging the sorted halves.
Divide the array into two halves
Recursively sort the two halves
Merge the sorted halves
Find pairs of integers in a BST whose sum is equal to a given number.
Traverse the BST and store the values in a hash set.
For each node, check if (X - node.value) exists in the hash set.
If yes, add the pair (node.value, X - node.value) to the result.
Continue traversal until all nodes are processed.
Merge overlapping time intervals into mutually exclusive intervals.
Sort the intervals based on their start time.
Iterate through the intervals and merge overlapping intervals.
Output the mutually exclusive intervals.
Example: [(1,3), (2,6), (8,10), (15,18)] -> [(1,6), (8,10), (15,18)]
Different types of hashing and alternative for Linear Chaining
Different types of hashing include division, multiplication, and universal hashing
Alternative for Linear Chaining is Open Addressing
Open Addressing includes Linear Probing, Quadratic Probing, and Double Hashing
An AVL tree is a self-balancing binary search tree where the heights of the left and right subtrees differ by at most one.
AVL tree is a binary search tree with additional balance factor for each node.
The balance factor is the difference between the heights of the left and right subtrees.
Insertion and deletion operations in AVL tree maintain the balance factor to ensure the tree remains balanced.
Rotations are performed ...
Find the minimum number of squares whose sum equals to a given number n.
Use dynamic programming to solve the problem efficiently.
Start with finding the square root of n and check if it is a perfect square.
If not, then try to find the minimum number of squares required for the remaining number.
Repeat the process until the remaining number becomes 0.
Return the minimum number of squares required for the given number n.
Insertion sort for a singly linked list.
Traverse the list and compare each node with the previous nodes
If the current node is smaller, swap it with the previous node
Repeat until the end of the list is reached
Time complexity is O(n^2)
Some of the top questions asked at the Times Internet Software Developer interview -
based on 1 interview
Interview experience
based on 12 reviews
Rating in categories
Senior Software Engineer
147
salaries
| ₹11 L/yr - ₹39 L/yr |
Product Manager
115
salaries
| ₹13.8 L/yr - ₹36.8 L/yr |
Software Developer
95
salaries
| ₹7.5 L/yr - ₹25.1 L/yr |
Manager
73
salaries
| ₹7.5 L/yr - ₹30 L/yr |
Software Engineer
65
salaries
| ₹5.9 L/yr - ₹24.1 L/yr |
Amazon
Flipkart
Indiamart Intermesh
BigBasket