Amity MSC IT Sem II Solved Assignment for Object-Oriented Programming  | SolveZone
whatssapp

Product Detail

Amity MSC IT Sem II Solved Assignment for Object-Oriented Programming 

University  Amity blog
Service Type Blog
Course Assignment
Semester
Short Name or Subject Code Object-Oriented Programming 
Product Assignment of Blog (Amity blog)
Pattern Section A,B,C Wise
Price
Click to view price

ASSIGNMENT ON  
OBJECT ORIENTED PROGRAMMING 

Assignment A 

Q1) Differentiate between basic data types, derived data types and user defined data types?

Q2)  Explain mechanism in Object Oriented Programming System?
Q3) Explain about passing parameters to as function in Call by Value and Call by Reference and then distinguish between them?
Q4) What is Template? Explain the concept of Template in C++?
Q5) Write Short notes on:-

Assignment- B
Q1) Explain I-O Stream file?

Q2) Write a C++ program to create a data file with following attributes. S.No, name, age. Accept n persons information and display the same.
Q3) Write short note on Encapsulation and Data Binding with an Example?

Q4) Write a C++ program to find factorial of a given number using functions.

Q5) What are access specifier? Explain their purpose and different type of access specifier?

Q6) Write a C++ program to transpose a matrix using class concept.

Assignment- C
Q1) In Late binding the function calls gets resolved during
a) Compile Time 
b) Run Time
c) Both A and B
d) None of the Above
Q2) The value of EOF is
a) 1
b) 0
c) Infinity
d) -1
Q3) Using pointers to call a function is called as
a) call by value
b) call by reference
c) call by address
d) All the Above
Q4) The variable that contains address of another variable is called as
a) Pointer
b) Arrays
c) Unions
d) None of the Above
Q5) Inheritance in C++ have default access specifier as
a) Private
b) Public
c) Protected
d) None of the Above 
Q6) How many values can be returned by a C++ function?
a) 1
b) Infinity
c) 0
d) None of the Above
Q7) The array exforsys[10] can be declared using pointers as
a) % exforsys[]
b) & exforsys[]
c) * exforsys[]
d) @ exforsys[]
Q8) The variables that can be used only within the function in which it is declared is called as
a) Global Variables
b) Local Variables
c) Both A and B
d) None of the Above 

Q9) The class that in C++ for file input is
a) Ifstream
b) Ofstream
c) Both A and B
d) The class that in C++ for file input is
Q10) Which of the following is an error statement in C++ array declaration?
a) int exforsys(10);
b) float exforsys[5][5];
c) int exforsys[5];
d) None of the Above 

 Q11) The members of a class are by default
a) Private
b) Public
c) Protected
d) None of the Above
Q12) The header that should be included while using manipulators in C++ is iomanip.h
a) manip.h
b) ifstream.h
c) None of the Above
Q13) The header file that must be included while using cout function in a C++ program is
a) conio.h
b) math.h
c) iostream.h
d) none of the above
Q14) The other name for external variables in C++ is
a) static variables
b) register variables
c) global variables
d) None of the Above
Q15) A function in a C++ program can be called
a) Only Once
b) Cannot be called at all
c) Any number of times
d) None of the Above
Q16) Which of the following denotes feature of OOPS?
a) Inheritance
b) Encapsulation
c) Polymorphism
d) All the Above
Q17) What is used to convert C++ source code into object modules?
a) Compiler
b) Linker
c) Both A and B
d) None of the Above
Q18) Which of the looping structure in C++ check condition at the beginning of loop?
a) do-while
b) while
c) Both A and B
d) None of the Above
Q19) A condition that must be true on exit from a member function if called as
a) Precondition
b) Post-condition
c) Both A and B
d) None of the Above
Q20) The method that is used for writing characters in C++ program is
a) put
b) get
c) write
d) None of the Above
Q21) Which of the following denote incorrect data type in C++?
a) real
b) double
c) float
d) int
Q22) The isolation of data from direct access by a C+ program is called as
a) Data Hiding
b) Data Isolation
c) Data Encapsulation
d) None of the Above
Q23) Reference to its own class can be accepted by
a) simple constructor
b) copy constructor
c) Both A and B
d) None of the Above
Q24) What is the value of variable z when the following program segment ends? int z; for(z=0; z<50; z++)
{}
a) 51
b) 49
c) 0
d) 50
Q25) The actual implementation is present in
a) declaration
b) definition
c) Both A and B
d) None of the Above 

Q26) Which of the following OOPS concepts are used with cin and cout?
a) Encapsulation
b) Data Hiding
c) Operator Overloading
d) None of the Above
Q27)The friend function of a class in C++ can access
a) Private members of the class
b) protected members of the class
c) Both A and B
d) None of the Above
Q28) A function defined within a class is called as
a) Member Function
b) Class Function
c) Object Function
d) None of the Above

Q29) The private member in derived class
a) Cannot be inherited
b) Can be inherited at all instances
c) Can be inherited only if the derived class is inheriting from base class with private access level
d) None of the Above
Q30) Which of the following denote types of polymorphism in C++?
a) Virtual function
b) Function overloading
c) Operator Overloading
d) All the Above 
 
Q31) An instance of a user-defined type is called
a) Class
b) Object
c) Method
d) None of the Above 

Q32) Which of the following can be used to initialize a newly declared variable from an existing variable?
a) Virtual Function
b) Namespaces
c) copy constructor
d) None of the Above
Q33) The member functions of a class can be defined outside the class using
a) Extraction Operator
b) Insertion Operator
c) Scope resolution operator
d) None of the Above
Q34) The output of operation 20%3 is
a) 6
b) 2
c) 1
d) 4
Q35) A template can be instantiated by
a) Explicit Instantiation
b) Implicit instantiation
c) Both A and B
d) None of the Above 

Q36) A function named as exforsys has three implementations associated with it. This means the
function exforsys is
a) Overloaded
b) Overriding
c) Both A and B
d) None of the Above 

Q37) Which of the following denote bitwise operators of C++?
a) ^
b) <<
c) ~
d) All the Above 
 
 Q38) Virtual functions are defined in
a) Derived class
b) Base class
c) Both A and B
d) None of the Above
Q39) The data members and member functions that are only available to derived classes are
a) private
b) public
c) protected
d) None of the Above
Q40) Which of the following remains static in a C++ program?
a) Class
b) Object
c) Both A and B
d) None of the Above