- TCS Technical Interview Questions & Answers
- TCS Managerial Interview Questions & Answers
- TCS HR Interview Questions & Answers
- Overview of Cognizant Recruitment Process
- Cognizant Interview Questions: Technical
- Cognizant Interview Questions: HR Round
- Overview of Wipro Technologies Recruitment Rounds
- Wipro Interview Questions
- Technical Round
- HR Round
- Online Assessment Sample Questions
- Frequently Asked Questions
- Overview of Google Recruitment Process
- Google Interview Questions: Technical
- Google Interview Questions: HR round
- Interview Preparation Tips
- About Google
- Deloitte Technical Interview Questions
- Deloitte HR Interview Questions
- Deloitte Recruitment Process
- Technical Interview Questions and Answers
- Level 1 difficulty
- Level 2 difficulty
- Level 3 difficulty
- Behavioral Questions
- Eligibility Criteria for Mindtree Recruitment
- Mindtree Recruitment Process: Rounds Overview
- Skills required to crack Mindtree interview rounds
- Mindtree Recruitment Rounds: Sample Questions
- About Mindtree
- Preparing for Microsoft interview questions
- Microsoft technical interview questions
- Microsoft behavioural interview questions
- Aptitude Interview Questions
- Technical Interview Questions
- Easy
- Intermediate
- Hard
- HR Interview Questions
- Eligibility criteria
- Recruitment rounds & assessments
- Tech Mahindra interview questions - Technical round
- Tech Mahindra interview questions - HR round
- Hiring process at Mphasis
- Mphasis technical interview questions
- Mphasis HR interview questions
- About Mphasis
- Technical interview questions
- HR interview questions
- Recruitment process
- About Virtusa
- Goldman Sachs Interview Process
- Technical Questions for Goldman Sachs Interview
- Sample HR Question for Goldman Sachs Interview
- About Goldman Sachs
- Nagarro Recruitment Process
- Nagarro HR Interview Questions
- Nagarro Aptitude Test Questions
- Nagarro Technical Test Questions
- About Nagarro
- PwC Recruitment Process
- PwC Technical Interview Questions: Freshers and Experienced
- PwC Interview Questions for HR Rounds
- PwC Interview Preparation
- Frequently Asked Questions
- EY Technical Interview Questions (2023)
- EY Interview Questions for HR Round
- About EY
- Morgan Stanley Recruitment Process
- HR Questions for Morgan Stanley Interview
- HR Questions for Morgan Stanley Interview
- About Morgan Stanley
- Recruitment Process at Flipkart
- Technical Flipkart Interview Questions
- Code-Based Flipkart Interview Questions
- Sample Flipkart Interview Questions- HR Round
- Conclusion
- FAQs
- Recruitment Process at Paytm
- Technical Interview Questions for Paytm Interview
- HR Sample Questions for Paytm Interview
- About Paytm
- Most Probable Accenture Interview Questions
- Accenture Technical Interview Questions
- Accenture HR Interview Questions
- Amazon Recruitment Process
- Amazon Interview Rounds
- Common Amazon Interview Questions
- Amazon Interview Questions: Behavioral-based Questions
- Amazon Interview Questions: Leadership Principles
- Company-specific Amazon Interview Questions
- 43 Top Technical/ Coding Amazon Interview Questions
- Juspay Recruitment: Stages and Timeline
- Juspay Interview Questions and Answers
- How to prepare for Juspay interview questions
- Prepare for the Juspay Interview: Stages and Timeline
- Frequently Asked Questions
- Adobe Interview Questions - Technical
- Adobe Interview Questions - HR
- Recruitment Process at Adobe
- About Adobe
- Cisco technical interview questions
- Sample HR interview questions
- The recruitment process at Cisco
- About Cisco
- JP Morgan interview questions (Technical round)
- JP Morgan interview questions HR round)
- Recruitment process at JP Morgan
- About JP Morgan
- Wipro Elite NTH: Selection Process
- Wipro Elite NTH Technical Interview Questions
- Wipro Elite NTH Interview Round- HR Questions
- BYJU's BDA Interview Questions
- BYJU's SDE Interview Questions
- BYJU's HR Round Interview Questions
- A Quick Overview of the KPMG Recruitment Process
- Technical Questions for KPMG Interview
- HR Questions for KPMG Interview
- About KPMG
- DXC Technology Interview Process
- DCX Technical Interview Questions
- Sample HR Questions for DXC Technology
- About DXC Technology
- Recruitment Process at PayPal
- Technical Questions for PayPal Interview
- HR Sample Questions for PayPal Interview
- About PayPal
- Capgemini Recruitment Rounds
- Capgemini Interview Questions: Technical round
- Capgemini Interview Questions: HR round
- Preparation tips
- FAQs
- Technical interview questions for Siemens
- Sample HR questions for Siemens
- The recruitment process at Siemens
- About Siemens
- HCL Technical Interview Questions
- HR Interview Questions
- HCL Technologies Recruitment Process
- List of EPAM Interview Questions for Technical Interviews
- About EPAM
- Atlassian Interview Process
- Top Skills for Different Roles at Atlassian
- Atlassian Interview Questions: Technical Knowledge
- Atlassian Interview Questions: Behavioral Skills
- Atlassian Interview Questions: Tips for Effective Preparation
- Walmart Recruitment Process
- Walmart Interview Questions and Sample Answers (HR Round)
- Walmart Interview Questions and Sample Answers (Technical Round)
- Tips for Interviewing at Walmart and Interview Preparation Tips
- Frequently Asked Questions
- Uber Interview Questions For Engineering Profiles: Coding
- Technical Uber Interview Questions: Theoretical
- Uber Interview Question: HR Round
- Uber Recruitment Procedure
- About Uber Technologies Ltd.
- Intel Technical Interview Questions
- Computer Architecture Intel Interview Questions
- Intel DFT Interview Questions
- Intel Interview Questions for Verification Engineer Role
- Recruitment Process Overview
- Important Accenture HR Interview Questions
- Points to remember
- What is Selenium?
- What are the components of the Selenium suite?
- Why is it important to use Selenium?
- What's the major difference between Selenium 3.0 & Selenium 2.0?
- What is Automation testing and what are its benefits?
- What are the benefits of Selenium as an Automation Tool?
- What are the drawbacks to using Selenium for testing?
- Why should Selenium not be used as a web application or system testing tool?
- Is it possible to use selenium to launch web browsers?
- What does Selenese mean?
- What does it mean to be a locator?
- Identify the main difference between "assert", and "verify" commands within Selenium
- What does an exception test in Selenium mean?
- What does XPath mean in Selenium? Describe XPath Absolute & XPath Relation
- What is the difference in Xpath between "//"? and "/"?
- What is the difference between "type" and the "typeAndWait" commands within Selenium?
- Distinguish between findElement() & findElements() in context of Selenium
- How long will Selenium wait before a website is loaded fully?
- What is the difference between the driver.close() and driver.quit() commands in Selenium?
- Describe the different navigation commands that Selenium supports
- What is Selenium's approach to the same-origin policy?
- Explain the difference between findElement() in Selenium and findElements()
- Explain the pause function in SeleniumIDE
- Explain the differences between different frameworks and how they are connected to Selenium's Robot Framework
- What are your thoughts on the Page Object Model within the context of Selenium
- What are your thoughts on Jenkins?
- What are the parameters that selenium commands come with a minimum?
- How can you tell the differences in the Absolute pathway as well as Relative Path?
- What's the distinction in Assert or Verify declarations within Selenium?
- What are the points of verification that are in Selenium?
- Define Implicit wait, Explicit wait, and Fluent
- Can Selenium manage windows-based pop-ups?
- What's the definition of an Object Repository?
- What is the main difference between obtainwindowhandle() as well as the getwindowhandles ()?
- What are the various types of Annotations that are used in Selenium?
- What is the main difference in the setsSpeed() or sleep() methods?
- What is the way to retrieve the alert message?
- How do you determine the exact location of an element on the web?
- Why do we use Selenium RC?
- What are the benefits or advantages of Selenium RC?
- Do you have a list of the technical limitations when making use of Selenium RC? Selenium RC?
- What's the reason to utilize the TestNG together with Selenium?
- What Language do you prefer to use to build test case sets in Selenium?
- What are Start and Breakpoints?
- What is the purpose of this capability relevant in relation to Selenium?
- When do you use AutoIT?
- Do you have a reason why you require Session management in Selenium?
- Are you able to automatize CAPTCHA?
- How can we launch various browsers on Selenium?
- Why should you select Selenium rather than QTP (Quick Test Professional)?
- Airbus Interview Questions and Answers: HR/ Behavioral
- Industry/ Company-Specific Airbus Interview Questions
- Airbus Interview Questions and Answers: Aptitude
- Airbus Software Engineer Interview Questions and Answers: Technical
- Importance of Spring Framework
- Spring Interview Questions (Basic)
- Advanced Spring Interview Questions
- C++ Interview Questions and Answers: The Basics
- C++ Interview Questions: Intermediate
- C++ Interview Questions And Answers With Code Examples
- C++ Interview Questions and Answers: Advanced
- Test Your Skills: Quiz Time
- MBA Interview Questions: B.Com Economics
- B.Com Marketing
- B.Com Finance
- B.Com Accounting and Finance
- Business Studies
- Chartered Accountant
- Q1. Please tell us something about yourself/ Introduce yourself to us.
- Q2. Describe yourself in one word.
- Q3. Tell us about your strengths and weaknesses.
- Q4. Why did you apply for this job/ What attracted you to this role?
- Q5. What are your hobbies?
- Q6. Where do you see yourself in five years OR What are your long-term goals?
- Q7. Why do you want to work with this company?
- Q8. Tell us what you know about our organization
- Q9. Do you have any idea about our biggest competitors?
- Q10. What motivates you to do a good job?
- Q11. What is an ideal job for you?
- Q12. What is the difference between a group and a team?
- Q13. Are you a team player/ Do you like to work in teams?
- Q14. Are you good at handling pressure/ deadlines?
- Q15. When can you start?
- Q16. How flexible are you regarding overtime?
- Q17. Are you willing to relocate for work?
- Q18. Why do you think you are the right candidate for this job?
- Q19. How can you be an asset to the organization?
- Q20. What is your salary expectation?
- Q21. How long do you plan to remain with this company?
- Q22. What is your objective in life?
- Q23. Would you like to pursue your Master's degree anytime soon?
- Q24. How have you planned to achieve your career goal?
- Q25. Can you tell us about your biggest achievement in life?
- Q26. What was the most challenging decision you ever made?
- Q27. What kind of work environment do you prefer to work in?
- Q28. What is the difference between a smart worker and a hard worker?
- Q29. What will you do if you don't get hired?
- Q30. Tell us three things that are most important for you in a job.
- Q31. Who is your role model and what have you learned from him/her?
- Q32. In case of a disagreement, how do you handle the situation?
- Q33. What is the difference between confidence and overconfidence?
- Q34. If you have more than enough money in hand right now, would you still want to work?
- Q35. Do you have any questions for us?
- Interview Tips for Freshers
- Tell me about yourself
- What are your greatest strengths?
- What are your greatest weaknesses?
- Tell me about something you did that you now feel a little ashamed of
- Why are you leaving (or did you leave) this position??
- 15+ resources for preparing most-asked interview questions
- CoCubes Interview Process Overview
- Common CoCubes Interview Questions
- Key Areas to Focus on for CoCubes Interview Preparation
- Conclusion
- Frequently Asked Questions (FAQs)
- Data Analyst Interview Questions With Answers
- About Data Analyst
Top 50+ TCS Interview Questions and Answers for Freshers 2025
Dreaming of a career at Tata Consultancy Services (TCS)? Before you step into the interview room, it's important to know what to expect and how to answer with confidence. In this article, we’ll walk you through the types of questions asked at TCS and how to answer them confidently!
About TCS
Tata Consultancy Services (TCS) is a global leader in IT services, consulting, and business solutions. Headquartered in Mumbai, India, TCS operates in 46 countries with a workforce of over 500,000 professionals, making it one of the largest multinational IT service providers in the world.
The TCS hiring process typically consists of four key rounds:
- Written Exam (Logical Reasoning, Verbal Ability, etc.)
- Technical Interview
- Managerial Interview
- HR Interview
TCS Technical Interview Questions & Answers
These TCS interview questions are designed to assess your technical knowledge and programming skills. Interviewers may also inquire about your academic projects to evaluate your practical understanding and problem-solving abilities.
Whether you're a fresher or an experienced candidate, these questions can help you brush up on your technical subjects and prepare effectively for the interview.
1. Explain SDLC?
SDLC stands for Software Development Life Cycle (SDLC). It represents software development from the stages of the requirement analysis to maintenance and support. The entire process comprises seven steps:
- Analysis
- Planning
- Definition
- Design
- Development
- Testing
- Deployment
- Support

2. What do you mean by the waterfall model?
The waterfall model divides project activities into two sections, beginning and end. This division is similar to the top and bottom of a waterfall. However, in this model, one stage always precedes the other. In other words, it is a traditional software development lifecycle approach that progresses linearly through distinct phases, with each phase building upon the results of the previous one.
3. Name the most popular SDLC model.
Presently, the most popular model is AGILE. The main reason for its popularity is the low error probability during production. In AGILE, you use the continuous iteration methodology to reduce errors.
4. List the essential differences between C & C++.
This is a very common TCS interview question asked to assess your C and C++ knowledge.
| C | C++ |
| A procedural language; no class concept, objects, inheritance, encapsulation, and polymorphism | It uses Object Oriented Programming System (OOPS). It has polymorphism, encapsulation, inheritance, and class concepts. |
| Malloc() and calloc() functions do the dynamic memory allocation. | The new operator does the memory allocation. |
| There is no operator and function overloading in C. |
You can overload functions and operators in C++. |
| You cannot run C++ code. |
You can run C code. |
| Input and output are through scanf and printf. |
C++ uses cin and cout for input and output. |
| You can handle exceptions. |
You cannot handle exceptions. |
5. Name some differences between C++ and JAVA.
Java is an object-oriented programming language similar to C++. However, there are some differences.
| C++ | JAVA |
| It is a platform-dependent language. | It's a platform-independent language. |
| It is primarily used for system programming. | It is primarily used for application programming. |
| You can use pass-by-value and pass-by-reference for variables. | You can only pass variables by the value. |
| You can write blocks of code explicitly for pointers. | There is only limited support for pointers in Java; you can only use them internally in a program. |
| You can overload the operator. | You cannot use operator overloading. |
| There is support for multiple inheritances. | You cannot have multiple inheritances in JAVA. |
6. What is OOPS, and how does C++ use it?

OOPS stands for object-oriented programming that considers everything as objects while designing a program. It increases the ease of programming. Its basic principles of object-oriented are:
- Class: It contains methods and variables. Using a type, you can create objects. It is declared using a class keyword.
- Inheritance: You can create parent and child classes, where a child class has some of the properties of the parent class. It is similar to biological ones, where progeny share traits with their parents. The different types of inheritance are Single inheritance, multiple inheritance, multi-level inheritance, hierarchical inheritance, and hybrid inheritance.
- Polymorphism: You can create the same objects with different jobs. For example, you can create multiple functions with identical names. It occurs when there are many classes with the same parent class. You can achieve polymorphism using function and operator overloading.
- Abstraction: You can hide what an object does and show only what the thing is. You do this because every user may not need to know how an object works. It is similar to how a consumer doesn't need to understand how a laptop works to use it.
- Encapsulation: It is the concept of hiding code and data in a single unit. For example, variables and methods may be inaccessible outside the class holding them.
Note: Considering the importance of this topic, TCS interview questions can be centered around OOPs. Click here to for some important OOPS interview questions
7. How can you differentiate between Structs and Classes?
Struct refers to a custom data type that has public members by default. Therefore, for private structs, we need to use a modifier. Likewise, classes have private members by default; you need to use a modifier to make public members. Another difference between the two is that you can inherit a class but not a struct.
Read more about structs and classes
8. What are pointers?
Pointers store the address of variables. You can use them to pass variables by reference using their addresses.

For example:
int a = 23;
int *ptr = &a;
cout<< ptr;
In this example, ptr has the a's address. So, by writing *ptr, we get the value that the pointer refers to, 23.
9. Differentiate between a reference and a pointer.
Pointer stores the address of a variable, whereas reference is only a variable's copy having a different name.
You need to initialize a reference, but you don't need to do that in the case of a pointer.
For example,
int a;
int *ptr = &a;
int a = 20;
int &ref = a;
The above example shows a pointer and a reference. The ptr will store a's address, and the ref will store the value.
10. Describe virtual functions.
If you mark any class function as virtual, its implementation is exclusive to the parent object. Any inherited class must have its definition of the virtual function. For example, if a class student has a function Uniform as virtual, an inherited class Headboy must define its function Uniform. Virtual functions are those functions that an inherited class must override.
One click. Endless opportunities. Land your dream job today!
11. What are the examples of data structures in C++?
There are two types of C++ data structures:
- Linear: Here, you store data elements in a sequence. A stack, ques, and a linked list are some examples.
- Non-linear: These are not sequential, for example, a tree and a graph.
12. What is the disadvantage of using C++?
The main two disadvantages of C++ are that there is no built-in support for threads and it doesn't have garbage collection.
13. Define friend functions and classes.
A friend function is a function that is not a member of a class but is granted access to the private and protected members of that class. This access allows the friend function to manipulate or retrieve data from the class. Friend functions are often used when an operation involves multiple classes but doesn't naturally belong to any one of them as a member function. For example:
CODE SNIPPET IS HERE
Y2xhc3MgTXlDbGFzcyB7CnByaXZhdGU6CmludCBkYXRhOwoKZnJpZW5kIHZvaWQgZnJpZW5kRnVuY3Rpb24oTXlDbGFzcyYgb2JqKTsKCnB1YmxpYzoKTXlDbGFzcyhpbnQgZCkgOiBkYXRhKGQpIHt9Cn07Cgp2b2lkIGZyaWVuZEZ1bmN0aW9uKE15Q2xhc3MmIG9iaikgewpvYmouZGF0YSA9IDQyOyAvLyBBY2Nlc3NpbmcgcHJpdmF0ZSBtZW1iZXIgb2YgTXlDbGFzcwp9
A friend class is a class that is granted access to the private and protected members of another class. This means that the friend class can directly access the private and protected members of the class it is friends with. Friend classes are often used when two or more classes need to collaborate closely, sharing data and operations.
CODE SNIPPET IS HERE
Y2xhc3MgTXlDbGFzcyB7CnByaXZhdGU6CmludCBkYXRhOwoKZnJpZW5kIGNsYXNzIEZyaWVuZENsYXNzOyAvLyBHcmFudCBGcmllbmRDbGFzcyBhY2Nlc3MgdG8gcHJpdmF0ZSBtZW1iZXJzCgpwdWJsaWM6Ck15Q2xhc3MoaW50IGQpIDogZGF0YShkKSB7fQp9OwoKY2xhc3MgRnJpZW5kQ2xhc3MgewpwdWJsaWM6CnZvaWQgbW9kaWZ5RGF0YShNeUNsYXNzJiBvYmopIHsKb2JqLmRhdGEgPSA0MjsgLy8gQWNjZXNzaW5nIHByaXZhdGUgbWVtYmVyIG9mIE15Q2xhc3MKfQp9Ow==
14. How can you implement polymorphism in JAVA?
You can overload a method, also known as static polymorphism. Here, a method can have the same name but different parameters. The computer finds the appropriate method by the parameter list.
For example:
CODE SNIPPET IS HERE
UHJpbnQoU3RyaW5nIG5hbWUpewoKLy8gYmFzaWMgY29kZQoKfQoKcHJpbnQoU3RyaW5nW10gc3ViamVjdHMsIFN0cmluZyBuYW1lKXsKCi8vYmFzaWMgY29kZQoKfQoKaWYoc3ViamVjdHMubGVuZ3RoPjApewoKcHJpbnQoU3RyaW5nW10gc3ViamVjdHMsIFN0cmluZyBuYW1lKTsKCn1lbHNlIGlmKG1hcmtzPjApewoKcHJpbnQoaW50IG1hcmtzLCBTdHJpbmcgbmFtZSk7Cgp9ZWxzZQoKcHJpbnQoU3RyaW5nIG5hbWUpOw==
Overriding or dynamic polymorphism - Here, the appropriate method gets called at the runtime. For example,
CODE SNIPPET IS HERE
Y2xhc3MgRG91Z2hudXRTaG9wewoKdm9pZCBwcmVwYXJlRG91Z2goKXsKClN5c3RlbS5vdXQucHJpbnRsbigiRG91Z2hudXQgc2hvcCBmcmVzaCBkb3VnaCBpcyByZWFkeSIpOwoKfQoKfQoKY2xhc3MgSW5kaWFuRG9obnV0c2hvcCBleHRlbmRzIERvdWdobnV0U2hvcHsKCnZvaWQgcHJlcGFyZURvdWdoKCl7CgpTeXN0ZW0ub3V0LnByaW50bG4oIldlbGNvbWUgdG8gSW5kaWFuRG91Z2hudXQsIGZyZXNoIGRvdWdoIHJlYWR5Iik7Cgp9Cgp9CgovL2luIHRoZSBtYWluIGNsYXNzCgpwdWJsaWMgc3RhdGljIHZvaWQgbWFpbihTdHJpbmdbXSBhcmdzKSB7CgpEb3VnaE51dFNob3AgZG91Z2hudXQgPSBuZXcgSW5kaWFuRG9obnV0c2hvcCAoKTsKCmRvdWdobnV0LnByZXBhcmVEb3VnaHQoKTsKCn0=
The output will be 'IndianDoughnut, fresh dough ready' in the above example. Here, the method prepareDough() gets overridden by IndianDoughnutshop during runtime.
15. Differentiate between stack and heap memory.
- Heap Memory: Java Runtime Environment (JRE) allocates heap memory for objects and JRE classes. Additionally, heap memory does the garbage collection, and you can globally access the objects created on the heap.
- Stack Memory: You use this memory for short-term references, including references to heap objects. A new memory block gets created when the program calls a method; after execution, another program uses the block of statement.
16. Write a program to check for the prime number.
The below program uses several if-then statements to check for the prime number.
CODE SNIPPET IS HERE
Ym9vbGVhbiBmbGFnID0gZmFsc2U7Cgpmb3IoaW50IGkgPSAyOyBpPD0gbnVtYmVyLzIsICsraSkKCnsKCmlmKG51bWJlciAlIGkgPT0gMCkgLy8gY29uZGl0aW9uYWwgc3RhdGVtZW50IHRvIGNoZWNrIGlmIHRoZSBudW1iZXIgaXMgcGVyZmVjdGx5IGRpdmlzaWJsZSBieSBpCgp7IGZsYWcgPSB0cnVlOwoKYnJlYWs7Cgp9Cgp9CgppZiAoIWZsYWcpIC8vIGNvbmRpdGlvbmFsIHN0YXRlbWVudCB0byBjaGVjayBpZiB0aGVyZSBpcyBhIGZsYWcuCgpTeXN0ZW0ub3V0LnByaW50bG4obnVtYmVyICsgImlzIHByaW1lLiIpOwoKZWxzZQoKU3lzdGVtLm91dHByaW50bG4obnVtYmVyICsgImlzIG5vdCBwcmltZS4iKTs=
17. Explain inheritance with an example.
In inheritance, you can create a child class of a class. By doing this, the child class can access the methods of the parent class.
For example,
class A{}
class B extends A{}
interface c{}
class D extends A implements C{}
18. Explain the process of exception handling in C++ and Java.
Both C++ and Java use try/catch algorithms to handle exceptions. There are, however, significant differences.
- You can only throw exceptions for a Throwable class or its subclasses in Java. However, in C++, you can throw even primitive types and pointers as an exception.
- Java has a final block executed after throwing an exception; there is no such block in C++.
- The keywords are different for C++ and Java exception handling. Java uses 'throws'; C++ uses to throw.
- You can only have unchecked expressions in C++. Java can have both checked and unchecked expressions.
Note: Besides TCS Interview questions, most leading firms frame their technical interview questions on languages like Java. Here are some frequently asked Java interview questions.
19. Explain null objects and their memory allocation.
Null is the name given to a situation when a non-primitive variable doesn't point to any object.
- To declare null, you can use String str=null;
- To find null, you can use if(str==null);
- To throw NullPointerException, you can use int length = str.length();\
20. Differentiate between an Array and an ArrayList.
ArrayList is dynamic, whereas an array has a fixed length. Another difference is that one cannot store primitives in ArrayList, but it is possible in Array.
Read More: Understand the advantages and disadvantages of array.
21. Write a program to swap two numbers.
Following is a program to swap two numbers.
int temp = 0;
temp = number1;
number1 = number2;
number2 = temp;
22. Write the above program without using a temporary variable.
Following is a program that doesn't have a temporary variable.
number1 = number1 + number2
number2 = number1 - number2
number1 = number1 - number2
23. Define circular linked list.
In a list, each node connects to the previous node. In a circular linked list, the last node connects to the first node; this completes a circle.
24. List different modifiers in Java.
Modifiers in Java are:
- Public
- Private
- Protected
- Default
25. Define class and create an object for a static class.
In a class, you can integrate both variables and methods. For example, a Class Teacher can have all the details of a teacher, such as a name, teaching subject, etc. If an application wants a teacher's particulars, it fetches an object of this class.
You can create an object of a class Teacher, using Teacher teacher1 = new Teacher();
You cannot have static outer classes in Java; only the nested class can be static.
public class Outer {
public static class Neste {
}
}
You can create an object of static class as follows -
public class Test {
Outer.Nested obj = new Outer.Nested();
}
26. How many types of loops are there in Java?
Java has three types of loops:
- For loop
- While loop
- Do while loop
27. What are constructors and destructors?
A constructor is a method for initializing an object with the class's name. On the other hand, a destructor deletes extra resources of an object; it gets called automatically after the object is out of the scope.
28. What is a database schema?
A logical representation or structure of the entire database is the Schema. It tells you how the database organizes, associates, and stores data. Suppose it is a rational database, then the organization is in the form of database tables. A database schema is a series of formulas known as integrity constraints imposed on a database.
There are two types of Schema:
- Physical
- Logical
Physical Schema describes the arrangement of data at a physical level (HDD, SDD, etc.) Logical Schema describes the arrangement of data at a logical level where programmers and database administrators work.
29. Define RDBMS.
RDBMS is the abbreviation of Relational Database Management System (RDBMS). It has a set of programs that allow the developer to interact with the database. For example, it allows them to create, update, or delete data. To do this, they use SQL queries.
30. Define Unique Key, Foreign Key, and Primary Key.
- Unique key: It is the set of one or more keys for identifying a database record. It does not include a primary key, and it can have a null value. For example, teacher_name and Salary can remember the teachers with top salaries.
- Primary Key: It refers to each row in a table, also called as parent table. For example, teacher_id may be the primary key for accessing a teacher's id in a teacher table. It can't be null.
- Foreign Key: A column in a table establishes a relationship with another table by referencing a column. You can use the primary key of one table as a foreign key for the other, and it is also called a child table. For example, the textbook table can have teacher_id as a foreign key that determines the teacher's textbooks.
31. Define clustered indexes
Indexes improve the query time. It is similar to a book index that makes navigation easier. A clustered index has an order of the table data. For example, consider a clustered index of the teacher_id column, the teacher with the teacher_id 6 gets stored in the sixth row.
32. Explain SQL joins and their use.
You can use SQL joins to get results from multiple tables into a single table using primary and foreign keys. For example, consider the following table.
| Table – teacher | table - books |
| teacher_id (primary key) | book_id (primary key) |
| teacher_name | book_title |
| teacher_batch | teacher_id (foreign key) |
| teacher_department | book_author |
You just need to post a query to get the book names a teacher has taken. elect teacher.teacher_name, book.book_title from teacher, book where teacher.teacher_id = book.teacher_id;
The results will be as follows:
| teacher_name | book_title |
| Madhuri | Java for beginners |
33. What is a leaf node?
The index's bottom-level node is a leaf node. It contains data pages of the underlying table in a clustered index.
34. Difference between tags and elements in HTML.
HTML tags define the starting and ending points of HTML elements. For example, you can create a heading element using the starting tag <h1> and the closing tag </h2>
35. What are attributes in HTML?
Attributes are used to specify the properties of the elements further. For example, <p align = "center"> HTML</p> has tag <p> and </p>, and the <p> tag has the attribute align = "center".
36. What do you mean by collapsing white space? What is its advantage?
HTML treats blank spaces as single-space characters. The developer does not have to worry about multiple spaces as the browser collapses them into a single one. Collapsing white space improves readability.
37. Define HTML Entities.
Some characters, such as '<', '>', '/', etc., are HTML entities. We need them to create the structure for an HTML block of code. You can see below a table of reserved characters.
|
Character |
Entity Name | Entity Number |
|---|---|---|
| < | < | < |
| > | > | > |
| & | & | & |
| (non-breaking space) E.g., 10 PM | Eg. <p>10  PM</p> |   |
38. Differentiate between a stack and a queue.
A stack has a linear structure where you can insert elements from only one side. That side is the Top; it follows the Last in First Out or LIFO principle. The element that gets into the stack last gets out first.
A queue is also a linear data structure where you can only insert elements from one side. However, you can only remove objects from the other side of a queue. It follows the First in First Out or FIFO principle.
39. What do you mean by a Binary Search Tree?
A Binary Search Tree is a data structure with the following properties:
- You can only have branch nodes, which hold prefix key values, with keys lesser than the node in the left subtree.
- In the right subtree, you can have branch nodes with keys greater than the node's key.
- You can't have any duplicates.
- The subtrees must also be binary search trees.
40. What is bubble sort?
This sorting algorithm compares two neighboring variables. If the first one is larger than the second, the values get swapped. This process continues for all the elements, and the sort will use several conditional expressions and loops.

41. What do you know about cloud computing?
Cloud computing uses hardware and software resources over the internet. It has three main categories: software as a service (SaaS), platform as a service (PaaS), and infrastructure as a service (IaaS). IaaS gives you the most control, and you only pay for the infrastructure. You have to install and maintain the software yourself.
42. Define directives, ifdef, and endif.
Before compiling, directives tell the computer to process the block of code. As these precede coding, a more specific name would be the preprocessor directive. They start with the hash(#) symbol. The most familiar one is #include used in C++.
#ifdef and #endif are conditional compilation directives that check a code block for conditions before compiling. If not satisfied, the code block will remain uncompiled.
43. Explain JVM and JIT.
JVM is the Java Virtual Machine that converts Java bytecodes into the native code of the machine. Java Virtual Machine enables Java to be platform-independent and provides class libraries.
JIT is Just In Time compilation that tells Java Virtual Machine not to compile the unchanged code the second time. This process saves compilation time. Together, JVM and JIT form the Java Runtime Environment or JRE.
44. What are the storage classes in C?
- Auto: This class is the default storage class for variables declared inside a function or a block. Tasks outside the block cannot access them.
- Register: It is the same as auto. However, the variables get stored in the microprocessor's registers for faster access. If the registers are not available, it stores the variables in the memory space.
- Static: These variables don't change their values once declared. They remain the same throughout the scope.
- External: This storage class allows the compiler to reuse a variable. You can overwrite a global variable using this class.
45. Define metadata and explain its purpose.
Metadata is the information about the data that an HTML document stores. For example, it can store keywords, page descriptions, etc. Browsers, search engines, and services can access this information.
46. Explain RR scheduling arguments.
RR stands for Round Robin; RR scheduling arguments are helpful for a time-sharing system. It consists of a CPU Scheduler that allocates CPU to various tasks for a particular time.
All processes get an equal share of CPU; however, you might need to face low throughput, larger waiting time, context switches, and response time.
47. How to avoid memory leaks in C++?
A memory leak happens when developers dynamically allot memory and forget to deallocate. The incorrect use of the delete operation is the most common cause of memory leakage.
To avoid memory leaks:
- Instead of manual memory management, use smart pointers, for example, instead of char*, use std::string
- Never use raw pointer unless you are operating on an old library
48. What do you mean by concurrency control?
Concurrency control is the practice of controlling multiple operations without interfering. It helps complete database transactions within time and without errors.
DBMS uses a concurrency control mechanism for the following reasons:
-
-
- Achieving isolation
- Resolving read-write and write-write conflicts
- Maintaining database consistency.
- Tracking the interaction of concurrent transaction
-
49. Tell the name of different access specifiers in C++.
The different access specifiers in C++ are:
- Public: Other classes can access the data members and member methods that have been made public. Using the dot operator with the class object, they may be accessible from anywhere in the program.
- Private: The data members and member functions that are declared private cannot be accessed or viewed from outside the class. They can only be accessed from within the class.
- Protected: The data members and member functions that are declared protected are similar to private members, but they can be accessed in inherited classes.
50. What do you mean by pass by reference?
Pass by reference is a concept in C++ where a reference or pointer to a variable is passed as an argument to a function instead of making a copy of the variable in memory address. Any changes made to the parameter inside the function are reflected in the original variable outside the function when a variable is passed in by reference because the address of the variable is saved in a pointer variable inside the code.
51. Tell the full form of ACID rule.
ACID rule stands for Atomicity, Consistency, Isolation, and Durability. It is a collection of characteristics that ensures the accuracy of data in database transactions in spite of mistakes, power outages, and other crises.
52. What is a generic pointer?
A generic pointer, also known as a void pointer, is a pointer that does not have any associated data type. It can hold the address of any data type, but it is not associated with any specific data type. When we are unsure of the data type of the variable that the pointer points to, we use the generic pointer.
53. What is dynamic testing?
Software testing that involves running the program and assessing its performance is known as dynamic testing. It is also known as functional testing since it focuses on analyzing how the software operates and how it responds to different inputs and situations. Static testing, which analyzes the software's code without running it, is the reverse of dynamic testing.
TCS Managerial Interview Questions & Answers
1. How do you handle pressure or tight deadlines?
I stay calm and focused by breaking tasks into smaller goals. I prioritize based on urgency and use tools like to-do lists or planners. This helped me during college while managing exams and project submissions simultaneously.
2. Have you led a team before?
Yes, during my final year project, I led a team of four. I assigned roles based on strengths, scheduled regular updates, and ensured collaboration. We delivered a functional prototype ahead of time.
3. Tell me about a time you failed. How did you handle it?
I once missed a project deadline due to poor time estimation. I took responsibility, informed my mentor, and created a better time management strategy. I learned the importance of planning buffers into timelines.
4. How do you deal with a non-cooperative team member?
I try to understand their concerns through one-on-one discussions. If the issue continues, I communicate transparently with the team and, if needed, escalate to a mentor while ensuring team harmony.
5. How do you prioritize tasks when everything feels important?
I use the Eisenhower Matrix to classify tasks by urgency and importance. This helps me focus on what matters most and avoid being overwhelmed.
6. Have you handled conflict before?
Yes, during a group assignment, two members had differing opinions. I facilitated a discussion and encouraged compromise, and we agreed on a hybrid approach that satisfied both parties.
7. What would you do if your manager made a decision you disagree with?
I would respectfully present my perspective with supporting facts. If the manager decides otherwise, I’d align with the decision and focus on delivering my best.
8. Are you a team player or an individual contributor?
I value both roles. I enjoy collaboration but can also take initiative and work independently when required. My adaptability helps in both situations.
9. Describe a situation when you took initiative.
I noticed declining participation in my college coding club. I proposed and organized a mini hackathon, promoted it, and increased engagement by 60%.
10. What are your long-term goals?
I aim to grow into a leadership role, gaining technical expertise in the short term and eventually managing key projects or teams within a reputed company like TCS.
TCS HR Interview Questions & Answers
1. Tell me about yourself.
I’m a Computer Science graduate from XYZ University with a strong interest in software development. I enjoy problem-solving and learning new technologies. I'm a quick learner, enthusiastic, and ready to begin my career with TCS.
2. Why should we hire you?
I bring a fresh perspective, adaptability, and strong foundational knowledge. I’m eager to learn, passionate about technology, and dedicated to contributing meaningfully to your team.
3. Why do you want to work at TCS?
TCS stands out for its global presence, innovation-driven culture, and career development opportunities. Being part of such a respected organization would allow me to learn, grow, and contribute to impactful projects.
4. What are your strengths and weaknesses?
Answer: My strengths are adaptability, teamwork, and problem-solving. My weakness is over-committing at times, but I’m learning to manage time better and set realistic expectations.
5. Are you willing to relocate?
Yes, I’m open to relocation and flexible in work location. I see it as an opportunity to learn from diverse environments and grow professionally.
6. Are you comfortable working in shifts?
Yes, I understand that IT roles may require night shifts or rotational shifts. I am flexible and prepared for such schedules.
7. What do you know about TCS?
TCS is one of the world’s leading IT services companies, with a strong presence in over 40 countries. It is known for innovation, sustainability, and employee-centric policies.
8. How do you handle criticism?
I see criticism as a learning opportunity. I stay open-minded, evaluate feedback constructively, and make efforts to improve my performance.
9. Where do you see yourself in five years?
I see myself gaining deep technical knowledge, possibly leading a team or project, and contributing significantly to TCS's goals while pursuing certifications and personal growth.
10. Do you have any questions for us?
Answer: Yes, I’d like to know more about the training programs for freshers and how performance is evaluated during the initial period.
Conclusion
Preparing for the TCS interview process means understanding each round—technical, managerial, and HR. While technical interviews test your subject knowledge, managerial and HR rounds evaluate your soft skills, decision-making, and cultural fit. As a fresher, focus on practicing common questions, tailoring your answers, and showing a positive attitude and eagerness to learn. With the right preparation and confidence, you can successfully clear the TCS interview and begin your career on a strong note.
Suggested Reads:
I am a storyteller by nature. At Unstop, I tell stories ripe with promise and inspiration, and in life, I voice out the stories of our four-legged furry friends. Providing a prospect of a good life filled with equal opportunities to students and our pawsome buddies helps me sleep better at night. And for those rainy evenings, I turn to my colors.
Login to continue reading
And access exclusive content, personalized recommendations, and career-boosting opportunities.
Subscribe
to our newsletter


Comments
Add comment