L&T Interview Question For Recruitment: Most Asked Interview Question

5421
L&T Technology Services
L&T Technology Services

L&T Interview Question For Recruitment: Most Asked Interview Question

L&T Interview Question

1. What is Operating System?

An operating system is a program that acts as an interface between the software and the computer hardware.It is a specialized software that controls and monitors the execution of all other programs that reside in the computer, including application programs and other system software.

2. What are the different operating systems?

  • Batched operating systems
  • Distributed operating systems
  • Timesharing operating systems
  • Multi-programmed operating systems
  • Real-time operating systems

3. What is the difference between micro kernel and macro kernel?

Micro kernel: micro kernel is the kernel which runs minimal performance affecting services for operating system. In micro kernel operating system all other operations are performed by processor.

Macro Kernel: Macro Kernel is a combination of micro and monolithic kernel.

4. What is deadlock? Explain.

Deadlock is a specific situation or condition where two processes are waiting for each other to complete so that they can start. But this situation causes hang for both of them.

5. What is pass by value and pass by reference?

The terms “pass by value” and “pass by reference” are used to describe the two ways that variables can be passed on. Cliff notes version: : pass by value means the actual value is passed on. Pass by reference means that a number (called a memory address) is passed on, this address defines where the value is stored.

6. What is the advantage of OOP?

1. Simplicity: software objects model real world objects, so the complexity is reduced and the program structure is very clear;

2. Modularity: each object forms a separate entity whose internal workings are decoupled from other parts of the system;

3. Modifiability: it is easy to make minor changes in the data representation or the procedures in an OO program. Changes inside a class do not affect any other part of a program, since the only public interface that the external world has to a class is through the use of methods;

4. Extensibility: adding new features or responding to changing operating environments can be solved by introducing a few new objects and modifying some existing ones;

5. Maintainability: objects can be maintained separately, making locating and fixing problems easier;

6. Reusability: objects can be reused in different programs

7. What is a class?

A class is a user defined blueprint or prototype from which objects are created. It represents the set of properties or methods that are common to all objects of one type.

8. What is Pointer?

A POINTER IS JUST THE ADDRESS OF SOME location in memory. In Java, pointers play an important role behind the scenes in the form of references to objects. A Java variable of object type stores a reference to an object, which is just a pointer giving the address of that object in memory.

9. What is operator loading and polymorphism

Operator overloading is an important concept in C++. It is a type of polymorphism in which an operator is overloaded to give user defined meaning to it. … For example ‘+’ operator can be overloaded to perform addition on various data types, like for Integer, String(concatenation) etc.

10. What is a copy constructor?

A copy constructor is a member function which initializes an object using another object of the same class. A copy constructor has the following general function prototype: ClassName (const ClassName &old_obj); Following is a simple example of copy constructor. #include<iostream>

11. What is recursion?

A recursive function is a function that calls itself during its execution. This enables the function to repeat itself several times, outputting the result and the end of each iteration.

12. What is a Thread?

In Java, the flow of a execution is called Thread. Every java program has at least one thread called main thread, the Main thread is created by JVM. The user can define their own threads by extending Thread class (or) by implementing Runnable interface. Threads are executed concurrently.

13. What is Vector?

It is same as Array List.

  • Vector methods are synchronized.
  • Thread safety.
  • It also implements the Random Access.
  • Thread safety usually causes a performance hit.

14. What is meant by Local variable and Instance variable?

Local variables are defined in the method and scope of the variables that have existed inside the method itself.

An instance variable is defined inside the class and outside the method and scope of the variables exist throughout the class.

15. Write a Java program for Fibonacci number

public static int fibonacci(int number){
         if(number == 1 || number == 2){
             return 1;
         }
         return fibonacci(number-1) + fibonacci(number -2); //tail recursion
     } 

16. Java program for Fibonacci number

public static boolean isPrime(int number) {
         int sqrt = (int) Math.sqrt(number) + 1;
         for (int i = 2; i < sqrt; i++) {
             if (number % i == 0) {
                 // number is perfectly divisible - no prime
                 return false;
             }
         }
         return true;
     } 

17. Difference between Java and C++.

The main difference between java and C++ is; Java is platform independent language and it is mainly used for design web based application but C++ is platform dependent language and it is mainly used for design desktop application. Java has method overloading, but no operator overloading. This is important question for L&T Interview Question.

18. What is data structure?

A data structure is a particular way of organizing data in a computer so that it can be used effectively. For example, we can store a list of items having the same data-type using the array data structure.

19. What is the difference between a stack and a Queue?

Stack – Represents the collection of elements in Last In First Out order. Operations includes testing null stack, finding the top element in the stack, removal of top most element and adding elements on the top of the stack.

Queue – Represents the collection of elements in First In First Out order.Operations include testing null queue, finding the next element, removal of elements and inserting the elements from the queue.

Insertion of elements is at the end of the queue.Deletion of elements is from the beginning of the queue

20. What are the advantages of Linked List over an array?

The size of a linked list can be incremented at runtime which is impossible in the case of the array.

The List is not required to be contiguously present in the main memory, if the contiguous space is not available, the nodes can be stored anywhere in the memory connected through the links.

The number of elements in the linked list are limited to the available memory space while the number of elements in the array is limited to the size of an array.

21. List the area of applications of Data Structure.

  • Compiler Design,
  • Operating System,
  • Database Management System,
  • Statistical analysis package,
  • Numerical Analysis,
  • Graphics,
  • Artificial Intelligence,
  • Simulation

22. What is join in DBMS?

Joins in DBMS and Types (Inner, Outer, Theta, Equi, Left, Right): Joins can be simply defined as the combining or merging the related tuples from the two different relations into a single type. … A cartesian product is followed by a selection process results in joins. This is important question of L&T Interview Question.

23. What is primary key?

A primary key is a special relational database table column (or combination of columns) designated to uniquely identify all table records. A primary key’s main features are: It must contain a unique value for each row of data. It cannot contain null values.

For example, in the table below, CustomerNo, which displays the ID number assigned to different customers, is the primary key.

24. What is the difference between primary key and unique key?

Primary key will not accept NULL values whereas Unique key can accept one NULL value.

A table can have only primary key whereas there can be multiple unique key on a table.

A Clustered index automatically created when a primary key is defined whereas Unique key generates the non-clustered index.

25. What do you mean by 3NF in DBMS?

Third normal form (3NF) is the third step in normalizing a database and it builds on the first and second normal forms, 1NF and 2NF. 3NF states that all column reference in referenced data that are not dependent on the primary key should be removed.

If You Want To Get More Daily Such Interview Questions Updates Then Press Red Bell Icon At The Right Side of Page To Subscribe our Updates.

High Paying Jobs In L&T: Click here

Recruitment Process of L&T: Click here

L& Syllabus For Recruitment 2019-20: Click here

HR Interview Question of L&T: Click here

Join Whatsapp Group of Daily Jobs Updates for 2010-2020 Batch: Click Here

Subscribe Our Telegram Channel for Interview Questions: Click here

Also Read: Daily Morning Skin Care For Glowing Skin: Click here