HCL Freshers Interview Questions with Answers

1) What is an array?

In programming, Array is a collection of similar types of values in a single unit. Array stores data in a contiguous memory location.

2) Explain ISO/OSI Model and it's Layers?

The OSI model is a networking model for understanding and designing a network architecture that would be flexible, robust, and interoperable. Communication between different systems without requiring changes to the logic of the underlying hardware and software is the main purpose of the OSI model.

The ISO-OSI model has a seven-layer design architecture which is as follows:

  • Application Layer - It indicates the Network process to the application.
  • Session Layer - It indicates Interhost communication.
  • Transport Layer - It indicates the end to end communication and reliability.
  • Network Layer - It indicates Path determination and IP or logical addressing.
  • Data Link Layer - indicates MAC and LCC physical addressing.
  • Physical Layer - indicates Media signal and binary transmission.
  • Presentation Layer - It indicates Data representation and encryption

3) What are four pillars of OOPS?

The four pillars of OOPs are as follows:

  • Inheritance
  • Abstraction
  • Encapsulation
  • Polymorphism

4) What is Java?

Java is an object-oriented programming language to develop software. It is originated by Sun Microsystem by James Gosling and his followers. A popular quote for JAVA is “Write once run anywhere.” Therefore we can say that JAVA is a platform-independent language. It uses an interpreter rather than a compiler to convert source code to byte code. THen Byte code is converted to the object code. It enables programmers to write computer instructions using English-based commands instead of having to write in numeric codes. It is a secure and simple language. It supports automatic memory allocation and deallocation.

5) Write sql query to remove the duplicate record from a table.

SQL query to remove the duplicate record from a table is as follows:

DELETE FROM Table_name 
fieldname1 NOT IN 
FieldName2, FieldName2 

You can also find the distinct values from the tables by using the following query: Select distinct columnName from Table_name;

6) Why do you want to join HCL?

I want to fulfill my as well as the organizations requirement with the utilization of my skills to join this Organization.

7) Where you see yourself after 5 years?

It depends upon the situation.

8) What are aggregate functions in SQL?

A function is a unit of code that is used for the reusability of a program. An SQL aggregate function calculates on a set of values and returns a single value. The function should return a value. Some SQL aggregate functions are as follows:

  • AVG() - It returns the average of a set.
  • COUNT() - It returns the number of items in a set.
  • MAX() - It returns the maximum value in a set.
  • MIN() - It returns the minimum value in a set.
  • SUM() - It returns the sum of all or distinct values in a set.

9) How much Voltage do we use to run a computer?

A typical desktop computer uses about 65 to 250 watts. It further depends upon the hardware configuration.

10) Who is the father of the First Computer?

Charles Babbage is regarded as the father of the first Computer.

11) What are constraints in SQL?

Constraints are the rules or limits that we can apply to the type of data in a table

The available constraints in SQL are:

NOT NULL: This constraint tells us that we cannot store a null value in a column.

UNIQUE: This constraint when specified with a column, tells that all the values in the column must be unique. 

PRIMARY KEY: A primary key is a field that can uniquely identify each row in a table. Typically, used to specify a field in a table as the primary key.

FOREIGN KEY: A Foreign key is a field that can uniquely identify each row in another table.

CHECK: This constraint helps to validate the values of a column to meet a particular condition. 

DEFAULT: This constraint specifies a default value for the column when no value is specified by the user.

For instance, 

ID int(6) NOT NULL,
NAME varchar(10) NOT NULL,
ADDRESS varchar(20)

12) What is peep stack?

Peek Stack () is one of a stack function or you can say that an operation. It returns the value of the top most element of the stack without deleting that element from the stack.

13) What is a foreign key?

When we relate two tables then the primary key of the first table is declared as the foreign key for another table.

Leave A Comment :

Valid name is required.

Valid name is required.

Valid email id is required.