Searching about Infosys Interview Questions for 2015? Now check here complete details
1. Difference between C and C++?
a) C follows the procedural programming paradigm while C++
is a multiparadigm language (procedural as well as object oriented) In case of
C, importance is given to the steps or procedure of the program while C++
focuses on the data rather than the process. Also, it is easier to
implement/edit the code in case of C++ for the same reason.
b) In case of C, the data is not secured while the data is
secured (hidden) in C++ This difference is due to specific OOP features like
Data Hiding which are not present in C.
c) C is a lowlevel language while C++ is a middlelevel language
C is regarded as a lowlevel language (difficult interpretation & less user
friendly) while C++ has features of both lowlevel (concentration on what's
going on in the machine hardware) & highlevel languages (concentration on
the program itself) & hence is regarded as a middlelevel language.
d) C uses the topdown approach while C++ uses the bottomup
approach In case of C, the program is formulated step by step, each step is
processed into detail while in C++, the base elements are first formulated
which then are linked together to give rise to larger systems.
e) C is functiondriven while C++ is objectdriven Functions
are the building blocks of a C program while objects are building blocks of a
C++ program.
f) C++ supports function overloading while C does not
Overloading means two functions having the same name in the same program. This
can be done only in C++ with the help of Polymorphism (an OOP feature)
g) We can use functions inside structures in C++ but not in
C. In case of C++, functions can be used
inside a structure while structures
cannot contain functions in C.
h) The NAMESPACE feature in C++ is absent in case of C C++
uses NAMESPACE which avoid name collisions. For instance, two students enrolled
in the same university cannot have the same roll number while two students in
different universities might have the same roll number. The universities are
two different namespace & hence contain the same roll number (identifier)
but the same university (one namespace) cannot have two students with the same
roll number (identifier)
i) The standard input & output functions differ in the
two languages C uses scanf & printf while C++ uses cin>> &
cout<< as their respective input & output functions
j) C++ allows the use of reference variables while C does
not Reference variables allow two variable names to point to the same memory
location. We cannot use these variables in C programming.
k) C++ supports Exception Handling while C does not. C does
not support it "formally" but it can always be implemented by other
methods. Though you don't have the framework to throw & catch exceptions as
in C++.
2. What are the 4 basics of OOP?
Abstraction, Inheritance, Encapsulation, and Polymorphism.
3. What you mean by Object Relational DBMS?
An object-relational database (ORD), or object-relational
database management system (ORDBMS), is a database management system (DBMS)
similar to a relational database, but with an object-oriented database model:
objects, classes and inheritance are directly supported in database schemas and
in the query language. In addition, just as with proper relational systems, it
supports extension of the data model with custom data-types and methods.
4. What is null pointer?
When referring to computer memory, a null pointer is a command
used to direct a software program or operating system to an empty location in
the computer memory. Commonly, the null pointer is used to denote the end of
amemory search or processing event. In computer programming, a null pointer is
a pointer that does not point to any object or function. A nil pointer is a
false value. For example, 1 > 2 is a nil statement. In the programming
language C, NULL is an available command that can be used, where nil is an
available command used in the Pascal programming language.
5. What is database Schema?
The formal definition of database schema is a set of
formulas (sentences) called integrity constraints imposed on a database.
6. What are the different levels of database schema?
Conceptual schema- a map of concepts and their
relationships.
Logical schema- a map of entities and their attributes and relations
Physical schema- a particular implementation of a logical schema
Schema object- Oracle database object
Logical schema- a map of entities and their attributes and relations
Physical schema- a particular implementation of a logical schema
Schema object- Oracle database object
7. What you mean by Object Relational DBMS?
An objectrelational database (ORD), or objectrelational
database management system (ORDBMS), is a database management system (DBMS)
similar to a relational database, but with an objectoriented database model:
objects, classes and inheritance are directly supported in database schemas and
in the query language. In addition, just as with proper relational systems, it
supports extension of the data model with custom datatypes and methods.
8. Structural difference between bitmap and btree index?
Btree It is made of branch nodes and leaf nodes. Branch
nodes holds prefix key value along with the link to the leaf node. The leaf
node in turn contains the indexed value and rowed. Bitmap It simply consists of
bits for every single distinct value. It uses a string of bits to quickly
locate rows in a table. Used to index low cardinality columns.
9. What is difference between foreign key and reference key
?
Reference Key is the primary key that is referenced in the
other table (linked via the other tables Foreign Key). Foreign Key is how you
link the second table to the primary tables Primary Key (or Reference Key).
10. Tell how to check whether a linked list is circular.
Create two pointers, each set to the start of the list.
Update each as follows: while (pointer1) { pointer1 = pointer1>next;
pointer2 = pointer2>next; if (pointer2) pointer2=pointer2>next; if
(pointer1 == pointer2) { print ("circular\n"); } }
11. What is difference between foreign key and reference key
?
Reference Key is the primary key that is referenced in the
other table (linked via the other tables Foreign Key). Foreign Key is how you
link the second table to the primary tables Primary Key (or Reference Key).
12. What is WPF and WCF?
WPF/WCF application, need in .NET 3.0 Framework. This
application will cover the following concepts: WCF(Windows Communication
Foundation) The new service orientated attributes The use of interfaces The use
of callbacksAsynchronous delegates Creating the proxy WPF( Windows Presentation
Foundation ) Styles Templates Animations Databinding Multithreading a WPF
application
13. Tell me about DSN?
A Data Source Name (DSN) is the logical name that is used by
Open Database Connectivity (ODBC) to refer to the drive and other information
that is required to access data. The name is used by Internet Information
Services (IIS) for a connection to an ODBC data source, such as a Microsoft SQL
Server database.
14. Tell how to check whether a linked list is circular.
Create two pointers, each set to the start of the list.
Update each as follows:
while (pointer1) {
pointer1 = pointer1->next;
pointer2 = pointer2->next; if (pointer2) pointer2=pointer2->next;
if (pointer1 == pointer2) {
print (“circular\n”);
}
}
while (pointer1) {
pointer1 = pointer1->next;
pointer2 = pointer2->next; if (pointer2) pointer2=pointer2->next;
if (pointer1 == pointer2) {
print (“circular\n”);
}
}
Thus, these are the most commonly asked Infosys technical
interview questions. Read these Infosys technical interview questions for
better Interview process.
15. What is the difference between an EXE and a DLL?
The term EXE is a shortened version of the word executable
as it identifies the file as a program. On the other hand, DLL stands for
Dynamic Link Library, which commonly contains functions and procedures that can
be used by other programs.+
See More Questions and Answers
See More Questions and Answers