Top 1000+ Object Oriented Programming (OOP) Subject Mcqs Pdf Download Set No 10

Print/Downlaod pdf

451.A C++ class is similar to?

  1. Structure               
  2. Header File
  3. Library File
  4. None of the give

452. What problem (s may occur when we copy objects without using deep copy constructor?

  1. Dangling pointer
  2. Memory Leakage
  3. All of the given      
  4. System crash

453. Suppose that the Test class does not have an overloaded assignment operator. What happens when an assignment a=b; is given for two Test objects a and b?

  1. The automatic assignment operator is used
  2. The copy constructor is used          
  3. Compiler error
  4. Run-time error

454.A static member function can be called, even when a class is not?                   

  1. Declared
  2. Define
  3. Instantiated         
  4. Called

455.Identify which of the following overloaded operator function’s declaration is appropriate for the given call?

  1. Rational_number_1 + 2.325
  2. Where Rational_number_1 is an object of user defined class Rational_number.
  3. Rational_number operator+ (Rational_number & obj;
  4. Rational_number operator+ (double& obj;        
  5. Rational number operator+ (Rational number &obj, double& num;
  6. operator+ (double& obj;

456.provide the facility to access the data member?

  1. accessor function    
  2. private function
  3. inline function
  4. None of the given

457.Constant objects cannot change their state?

  1. True   
  2. False

458.The relationship indicates that an object contains other objects?

  1. None of given      
  2. ‘has-a’
  3. is-a’
  4. ‘be-

459.Which one of the following features of OOP is used to derive a class from another?

  1. Encapsulation
  2. Polymorphism
  3. Data hiding
  4. inheritance       

  1.    

460.is a relationship?

  1. Inheritance        
  2. Polymorphism
  3. abstraction
  4. encapsulation

461.satisfy the condition of polymorphism?

  1. Carbon
  2. Diamond
  3. Coal    
  4. all of the given  

462.A generalization-specialization relation between classes are implemented using?

  1. data hiding
  2. friend classes
  3. encapsulation
  4. inheritance

463.The >= operator can be overloaded?

  1. True         
  2. False

464.In order to free the memory occupied by the object, we use?

  1. Constructor
  2. Destructor      
  3. Shallow Copy
  4. Deep Copy

465.Which of the following is not an example of multiple inheritances?

  1. Mermaid
  2. Woman          
  3. None of the given
  4. Amphibious Vehicle

466.Static variable can be initialized more than once?

  1. True     
  2. False

467.A generic class showing all the common attributes and a behavior of other classes represents a very important feature in oop called?

  1. Inheritance      
  2. Encapsulation
  3. Polymorphisms
  4. Abstraction

468.In order to free the memory occupied by the object, we use?

  1. Constructor
  2. Destructor      
  3. Shallow Copy
  4. Deep Copy

469.Which of the following  is not an example of multiple inheritances?

  1. Mermaid
  2. Woman          
  3. None of the given
  4. Amphibious Vehicle

470.Static variable can be initialized more than once?

  1. True      
  2. False

471.A generic class showing all the common attributes and a behavior of other classes represents a very important feature in oop called?

  1. Inheritance      
  2. Encapsulation
  3. Polymorphism
  4. Abstraction

472.We can get only one unique value which can be used by all the objects of that class by the use of?

  1. static variables                       
  2. dynamic variables
  3. instance variables
  4. data members

473.A-member function having the same name as that of a class and a ~ sign with it is called?

  1. Constructor
  2. Getter
  3. Setter
  4. Destructor      

474. We can also use member functions with insertion and extraction objects

  1. True
  2. FALSE

475.If the statements int j, k; j = ; k= ; int* q, * r; extraction < < *q < < ‘ ‘ < < * r ; are executed, what will   be displayed?

  1. The values of j and k
  2. The addresses of q and r
  3. The addresses of j and k
  4. garbage values

476. Which one of the following operators is a unary operator?

  1. OR (||)
  2. AND (&&)
  3. XOR (^)
  4. Complement operator (~)

477. The statement i++; is equivalent to

  1. i = i + i;
  2. i = i +;
  3. i = i – ;
  4. i –;

478.If we open a file stream myfile for reading, what will give us the current position of the file pointer?

  1. tellg()
  2. tellp()
  3. seekg()
  4. seekp()

479.Application Software’s are used to?

  1. Type letters
  2. Control computer hardware
  3. Solve end user problems
  4. Develop Graphics

480. When we write a class template the first line must be?

  1. template < class class_type>
  2. template < class data_type>
  3. template < class T >, Here T can be replaced with any name but it is preferable.
  4. class template

481. When a macro takes arguments then it is called?

  1. Function
  2. Procedure
  3. Parameterized macro
  4. Simple macro

 482.By default an array of characters is passed by value to a function?

 TRUE

FALSE


483.Using dynamic memory is more efficient than the static memory?

  1. True
  2. FALSE

484. Using dynamic memory is more than the static memory?

  1. Costly
  2. Expansive
  3. efficient
  4. Difficult

485. Before exiting the program, make sure that the allocated memory has freed?        

  1. True      
  2. FALSE

486.A preprocessor directive is identified by  symbol?

  1. #
  2. $
  3. %
  4. ##

487.The default constructor has no arguments?

  1. True
  2. FALSE

488.The data members of the class are initialized at runtime?

  1. True
  2. FALSE

489.if (a>b && a>c) then the condition will be true only if?

  1. Both a>b and a>c is true
  2. a>b is false and a>c is true
  3. a>b is true and a>c is false
  4. Both a>b and a>c is false

490.In while loop the loop counter must be initialized?

  1. Within the loop
  2. Before entering the loop
  3. At the end of the loop
  4. None of the given s

491… of a variable means the locations within a program from where it can be accessed.

  1. Data type
  2. Visibility
  3. Value
  4. Reference

492. Switch support data.

  1. Integer
  2. Character
  3. Float
  4. Both integer and character

 493.A function is a block of statements that can be defined once and used ________ in the program.

  1. One time
  2. Two times
  3. Three times
  4. As many times as user wants

494. statement is used to terminate the processing of a particular case and exit from switch structure?

  1. if
  2. go to
  3. break

  495.The most suitable data type for number 5.5 is?

  1. char
  2. int
  3. short
  4. float 

496.X is an integer variable; what does X++ means?

  1. Add   two times in X value
  2. Add   in X value
  3. Add   in X value
  4. None  

 497.The operators ++ and –- are used to increment or decrement the value of a variable 

Which of the following loops checks the test condition at the end of the loop?

  1. While
  2. Do-While
  3. For
  4. Nested Loop

498.Information hiding is?

  1. Encapsulation, Inheritance
  2. Encapsulation, Abstraction
  3. Encapsulation, Polymorphism
  4. Overloading

499. The good model will be related to a real-life problem?

  1. Closely
  2. Loosely
  3. Openly
  4. All

500.Which features of OOP will be used to derive a class from another?

  1. Inheritance
  2. Encapsulation
  3. Polymorphism
  4. Data hiding