Explore topic-wise InterviewSolutions in Current Affairs.

This section includes 7 InterviewSolutions, each offering curated multiple-choice questions to sharpen your Current Affairs knowledge and support exam preparation. Choose a topic below to get started.

1.

Write a C++ program to check whether a number is palindrome or not.

Answer»

/* A palindrome number is a number that remains same after reversing the digits. */#include<iostream.h>#include<conio.h>void main(){ int num, n, rem, rev=0; clrscr(); cout<<"Enter a number:"; cin>>num; n=num; //Used for comparision after reversal of a number while(num>0) { /* In this block, we retrieve each digit from a given number and will get the reversed number at the end stored at rev variable. */ rem=num%10; rev=(rev*10)+rem; num=num/10; } if(n==rev) //Comparing given number with reversed number cout<<n<<" is a palindrome."; else cout<<n<<" is not a palindrome."; getch();}Conclusion:

We hope that you found this article very INFORMATIVE and useful for your preparations for the Infosys interview process. Now prepare yourself for every question thoroughly as this is going to upgrade your understanding of the Infosys recruitment process. In addition, you can also take imagination from these questions as to what type of questions are being asked in the Infosys interview process and how effectively your RESPONSES should be put across to the interviewer.

The Infosys interview will usually have a varied set of questions, however, the above questions will definitely touch every such aspect. In order to get a better hold on the Infosys interview questions, please spend your time learning deeper about concepts that are relevant to the job role.

If a particular candidate is not been selected, then Infosys does not allow him/her to re-apply for the next six months, hence give it your BEST shot so as to pursue your dream CAREER in Infosys. Remember, while no one can predict the questions that are going to be asked by the interviewer, preparation becomes the key element to succeed in the Infosys placement process. To be precise, the interview process at Infosys is not very difficult; so you should be able to grab the opportunity with heavy preparations and a little bit of luck. Know More.

2.

Explain different levels of programming languages.

Answer»

The various programming language levels are given below:

  • Low-level Language: Language which is directly understood by the machine is known as the low-level language (binary language or machine language). It is difficult for a human being to directly READ and do coding in this language.
  • Assembly level language: This language will make use of MNEMONICS, which minimizes the program complexity. It is quite similar to the computer understandable machine code, but it uses words in place of numbers.
  • Middle-level Language: It INTERACTS with the abstraction layer of a computer and binds the gap between high-level and machine-level language. For example, programming languages like C and C++.
  • High-level language: This is the highest level of the programming language in the technology, which has strong abstraction from the computer hardware details. That means this kind of programming language does not require hardware knowledge about computers. This programming language is simple to learn by human beings as it is in the human-understandable FORM. For example, Java, Perl, PHP, PYTHON, etc.
3.

Differentiate between white box and black box testing.

Answer»
White BOX testingBlack box testing
The tester will have complete knowledge about the internal working of the application.It is not necessary to KNOW the internal working of the application.
It is done by developers and testers(QA).It is done by the end-user and ALSO by developers and testers.
It is more time-consuming and exhaustive.It is LESS time-consuming and exhaustive.
Here, a tester will design test data and test cases.Testing is done based on an external or end-user perspective.
White box testing is also called an open box, glass, structural testing, clear box, or code-based testing.Black box testing is also called CLOSED box, functional, data-driven testing.
4.

What is a frame in HTML?

Answer»
  • HTML Frames are useful for DIVIDING browser windows into many parts where each section is able to LOAD an HTML document separately. A frame COLLECTION in the browser window is called a frameset.
  • It permits authors to present HTML DOCUMENTS in MULTIPLE views, which might be subwindows or independent windows. Multiple views provide help to keep specific information visible, while other views are replaced or scrollable.
5.

What is DLL and EXE file extension?

Answer»
  • EXE FILE extension is USED for executable files, it recognizes the file as a program. It runs INDEPENDENTLY. An EXE creates separate MEMORY and process SPACE for it.
  • DLL stands for a dynamic link library that has functions and procedures used by other applications. This DLL can be reused by multiple applications. It will share the same memory and process space of the calling application.
6.

Explain about Agile model.

Answer»
  • Agile is a SOFTWARE development model that has an iterative approach for software development that helps teams to deliver value to their customers faster, with greater quality, with lesser errors, greater ability to respond to change.
  • An agile team delivers a product in small increments instead of a “BIG bang” launch. Requirements, plans, and result evaluation is continuously DONE, so teams have a NATURAL mechanism for a quick response to change.
  • Scrum and Kanban are the most frequently USED Agile methodologies.
7.

What are the disadvantages of the Waterfall model?

Answer»
  • Working software is PRODUCED only at the end of the life cycle
  • Not suitable for COMPLEX as well as object-oriented projects.
  • Difficult to measure progress within each stage
  • Not recommended for the projects where requirements are frequent that may lead to a HIGH risk of changing. So, this model is having a high amount of risk and uncertainty.
  • It is difficult to identify any business or technological bottleneck or challenges EARLY because integration is done at the end.
8.

What is SDLC(Software Development Life Cycle)?

Answer»

SDLC is an end-to-end process that defines the software DEVELOPMENT flow starting from the requirements stage to the maintenance and support stage. The SDLC STAGES are requirements analysis, planning, definition, design, development, testing, DEPLOYMENT, maintenance, and support.

9.

What is meant by a null pointer?

Answer»
  • The POINTER that does not POINT to any memory location is called the null pointer. It IMPLIES the pointer is empty and it is not pointing to anywhere within the memory.
    Example: INT *pointer=NULL;
  • Null pointers can be used for initializing the memory location address with the pointer of the same DATA type.
    Example: int *pointer= (int*)NULL;
10.

Explain pointers in C++.

Answer»

A variable that holds the address of another variable of the same data type can be called a pointer. Pointers can be created for any data type or user-defined datatypes LIKE class, structure, etc. It allows variable passing by REFERENCES using the address. For example:

int x = 25;int *ptr = &x;cout << ptr;

Here, ptr will store the address of x. That means the address of x is the ptr value.
Using *ptr, we can obtain the value STORED in the address referenced by ptr(i.e., 25). *ptr is known as dereference operator.

Uses of pointers:

  • To point a variable PRESENT inside the memory.
  • To store addresses of dynamically allocated memory blocks.
11.

What is stored procedure?

Answer»

A stored procedure is a logical UNIT for a group of statements and is AVAILABLE for the applications that ACCESS an RDBMS(Relational Database Management System). These are stored in the database data DICTIONARY. It can be used for data validation or access-control MECHANISMS.

12.

What is the left outer join and the right outer join in SQL?

Answer»
  • LEFT outer JOIN: It returns an ENTIRE SET of records from the left table ALONG with the matched records from the right table.
  • Right outer join: It returns an entire set of records from the right table along with the matched records from the left table.
13.

Differentiate between DDL and DML commands in SQL.

Answer»
DDL(Data Definition Language)DML(Data Manipulation Language)
DDL is USED to define database SCHEMA and also to define some constraintsDML is used to manipulate the data within the database
Does not have further classificationClassified into procedural and non-procedural DML
DDL statements do not use WHERE clauseDML statements use WHERE clause
Examples for DDL statements are CREATE, ALTER, DROP, TRUNCATE, COMMENT, and RENAMEExamples for DML statements are INSERT, UPDATE, and DELETE
14.

Why indexing in SQL is useful ?

Answer»

A SQL index is a QUICK lookup table that helps to find records that are FREQUENTLY SEARCHED by a user. An index is fast, small, and OPTIMIZED for quick look-ups. It is useful for establishing a connection between the relational tables, searching large tables, and fast retrieval of data from a database.

15.

Differentiate between TRUNCATE and DELETE commands in SQL.

Answer»
TRUNCATEDELETE
It is used to remove all records from a database tableIt is used to delete specified records(ONE or more) from a database table
It is a Data Definition Language(DDL) commandIt is a Data Manipulation Language(DML) command
Faster than DELETE commandSlower compared to TRUNCATE command
Cannot be APPLIED for indexed views as it WORKS only on tablesCan be applied for indexed views
16.

What are DDL and DML commands in SQL?

Answer»
  • DDL refers to Data Definition Language. DDL commands are used to DEFINE database schema i.e., to CREATE and modify the database object structure in the database. Examples are CREATE, ALTER, DROP, TRUNCATE, etc.
  • DML refers to Data MANIPULATION Language. DML commands are used to manipulate the data within the database. Examples are: INSERT, UPDATE, DELETE.
17.

Distinguish between classes and interfaces in Java.

Answer»
ClassInterface
A class is a blueprint for the creation of objects with the same configuration for properties and methodsAn interface is a collection of properties and methods that HELPS to describe an object, but it does not provide implementation or INITIALIZATION for them
A class will have abstract or concrete methodsInterface will have abstract methods only. From Java 8 onwards, it supports static as well as default methods
Does not support multiple inheritance.Multiple Inheritance is supported
An interface can be implemented by a classInterface cannot be implemented by another interface, but it is possible to extend an interface
Using extends keyword, a class can be inherited from another classInterface cannot INHERIT a class, but it can inherit an interface
It can have all types of members(PUBLIC, private or, OTHERS)Members are public by default, but you can use other access specifiers also for the interface members
18.

How method overloading is different from method overriding?

Answer»

Method overloading MEANS methods are having the same name, but they differ either in the number of arguments or in the type of arguments. It is DONE during compile time, so it is known as compile-time POLYMORPHISM.

Method OVERRIDING means the ability to define subclass and super-class methods with the same name as well as the same method SIGNATURES, here the subclass method will override the super-class method. It is performed during run time, so it is known as run-time polymorphism.

19.

Can we implement multiple inheritances in Java?

Answer»

Java does not DIRECTLY support multiple INHERITANCES. But we can ACHIEVE multiple inheritances with the help of an interface. It is POSSIBLE to implement multiple interfaces into our program.

20.

Explain four major OOP concepts in Java.

Answer»

Four major concepts RELATED to object-oriented programmings are:

  1. Data encapsulation: It refers to combining both data and methods into a single unit called a class. Data encapsulation helps in hiding the data from an external world.
  2. Data abstraction: Representation of essential features excluding their BACKGROUND details is known as data abstraction.
  3. Inheritance: Deriving existing class properties into a new class is called inheritance. A newly DERIVED class is called the SUBCLASS(child class) and the existing class(parent class) is called the base class. It is helpful for the re-usability of code.
  4. Polymorphism: Polymorphism means the ability of an object to take multiple FORMS. In java, compile-time polymorphism is achieved with the help of method overloading, and run-time polymorphism is achieved with the help of method overriding.
Previous Next