Tech Mahindra Interview Questions
Practice with real Tech Mahindra interview questions
01
A Software Engineer was asked
Asked in 2024
Q. Explain the concept of normalization in DBMS and describe the different normal forms with examples.
Ans. Normalization is a database design technique that organizes tables to reduce redundancy and dependency. The different normal forms are: 1. First Normal Form (1NF): A table is in 1NF if it contains only atomic values and each column has unique names. For example, a table of student records should not have multiple values in a single column.
To convert to 1NF, we would split 'Courses' into a separate table:
2. Second Normal Form (2NF): A table is in 2NF if it is in 1NF and all non-key attributes are fully functional dependent on the primary key. For example:
To convert to 2NF, we can move 'ProductName' to a separate table:
3. Third Normal Form (3NF): A table is in 3NF if it is in 2NF and all the attributes are functionally dependent only on the primary key. For example:
To convert to 3NF, we separate the department details:
Normalization helps maintain data integrity and efficiency.
Software EngineerCore Concept
02
A Software Engineer was asked
Asked in 2025
Q. What is the system design round like at Tech Mahindra?
Ans. The system design round at Tech Mahindra typically assesses your ability to design scalable and efficient systems. You may be asked to design a URL shortening service like Bitly. The interviewer will look for your understanding of system components, data storage solutions, and API design.
A simple design might involve creating a service with the following components:
- A web server to handle HTTP requests.
- A database to store URL mappings.
- Hashing algorithms to generate unique short URLs.
You could sketch your design as follows:
1. Input URL is received by the web server.
2. A unique ID is generated using a hashing function.
3. The mapping of the unique ID to the original URL is stored in the database.
4. The short URL is returned to the user.
5. When accessing the short URL, the service retrieves the original URL from the database.
Make sure to discuss trade-offs, such as database choice (SQL vs. NoSQL) and scaling strategies.
Software EngineerCore Concept
