Tech Mahindra Pvt. Ltd interview experience Real time questions & tips from candidates to crack your interview

SDE - 1

Tech Mahindra Pvt. Ltd
upvote
share-icon
2 rounds | 3 Coding problems

Interview preparation journey

expand-icon
Preparation
Duration: 3 months
Topics: Data Structures, Pointers, OOPS, System Design, Algorithms, Dynamic Programming
Tip
Tip

Tip 1 : Regarding DSA preparation, I have a theory. 20 percent of the questions will be asked in 80 percent of the interview and 80 percent of the questions will be asked in 20 percent of the interviews. In short, some questions have a very high chance of coming up during the interviews and some have very low chance. We should focus more on the questions that have more chance of coming up in the interview.
Tip 2 : Try to find patterns in the questions. Group them according to a pattern for better understanding. Make notes in Excel, word or hand written and revise them.
Tip 3 : Try to solve the questions that have more chance of coming up in the interview with many different approaches.

Application process
Where: Campus
Eligibility: Above 6 CGPA
Resume Tip
Resume tip

Tip 1 : Make Sure that your resume is simple and also try to fit all the information in only one page.
Tip 2 : Have at least 2 projects with the latest technologies,Github link of projects should be provided

Interview rounds

01
Round
Medium
Video Call
Duration45 minutes
Interview date26 Mar 2022
Coding problem2

1. Maximum Subarray Sum

Moderate
35m average time
81% success
0/80
Asked in companies
QualcommUberAmazon

You are given an array 'arr' of length 'n', consisting of integers.


A subarray is a contiguous segment of an array. In other words, a subarray can be formed by removing 0 or more integers from the beginning and 0 or more integers from the end of an array.


Find the sum of the subarray (including empty subarray) having maximum sum among all subarrays.


The sum of an empty subarray is 0.


Example :
Input: 'arr' = [1, 2, 7, -4, 3, 2, -10, 9, 1]

Output: 11

Explanation: The subarray yielding the maximum sum is [1, 2, 7, -4, 3, 2].
Problem approach

You are given an array (ARR) of length N, consisting of integers. You have to find the sum of the subarray (including empty subarray) having maximum sum among all subarrays.
A subarray is a contiguous segment of an array. In other words, a subarray can be formed by removing 0 or more integers from the beginning, and 0 or more integers from the end of an array.

Try solving now

2. String Transformation

Moderate
23m average time
0/80
Asked in companies
OptumAmazonWalmart

Given a string (STR) of length N, you have to create a new string by performing the following operation:

Take the smallest character from the first 'K' characters of STR, remove it from STR and append it to the new string.

You have to perform this operation until STR is empty.

 Note:
The input string(STR) will not contain any spaces.

Assume that all characters in STR are lower case letters.

If characters less than 'K' remain, then append them in a sorted way to the new string.
Example:
Let the input string be "edcba" with K = 4.

Let the new string to be formed is initially empty, newString = "".
The first set of 4 characters are, ('e', 'd', 'c', 'b')
Out of these 4 characters, the smallest one is 'b' and hence we add it to the newString and it becomes, 
newString = "b"

The next set of 4 characters are, ('e', 'd', 'c', 'a')
Out of these 4 characters, the smallest one is 'a' and hence we add it to the newString and it becomes, 
newString = "ba"

Now we are left with "edc" and since we can't get a window of size 4, we sort them in the increasing order and append them to the newString.

Hence, newString thus formed will be "bacde".
Problem approach

Given a string (STR) of length N, you have to create a new string by performing the following operation:
Take the smallest character from the first 'K' characters of STR, remove it from STR and append it to the new string.
You have to perform this operation until STR is empty.
Note:
The input string(STR) will not contain any spaces.

Assume that all characters in STR are lower case letters.

If characters less than 'K' remain, then append them in a sorted way to the new string.

Try solving now
02
Round
Easy
HR Round
Duration30 minutes
Interview date26 Mar 2022
Coding problem1

1.

What are your hobbies?

What are your strengths?

Where do you see yourself in five years?

 

Problem approach

Tips : Be honest and say what you know, know yourself better to answer behavioral questions (your likes,dislikes,what if you are not hired etc.)

Here's your problem of the day

Solving this problem will increase your chance to get selected in this company

Skill covered: Programming

How do you remove whitespace from the start of a string?

Choose another skill to practice
Similar interview experiences
Software Engineer
1 rounds | 4 problems
Interviewed by Tech Mahindra Pvt. Ltd
1911 views
1 comments
0 upvotes
SDE - 1
2 rounds | 2 problems
Interviewed by Tech Mahindra Pvt. Ltd
1674 views
0 comments
0 upvotes
SDE - 1
2 rounds | 6 problems
Interviewed by Tech Mahindra Pvt. Ltd
0 views
0 comments
0 upvotes
SDE - 1
3 rounds | 3 problems
Interviewed by Tech Mahindra Pvt. Ltd
1414 views
0 comments
0 upvotes
Companies with similar interview experiences
company logo
SDE - 1
5 rounds | 12 problems
Interviewed by Amazon
115097 views
24 comments
0 upvotes
company logo
SDE - 1
4 rounds | 5 problems
Interviewed by Microsoft
58238 views
5 comments
0 upvotes
company logo
SDE - 1
3 rounds | 7 problems
Interviewed by Amazon
35147 views
7 comments
0 upvotes