• الصفحة الرئيسية
  • إتصل بنا
  • سياسة الخصوصية
Logo
  • الرئيسية
  • أفكار
  • صحة
  • معلومات
  • عجائب وغرائب
  • تكنولوجيا
الصفحة الرئيسية C++ Multiple Choice Question (MCQ) Programming Language MCQ of C++ with answer Set-2

MCQ of C++ with answer Set-2

الكاتب ahmed في 4:45 AM C++ Multiple Choice Question (MCQ) Programming Language

1. The ……………. Operator is known as insertion operator.
A) >>
B) >
C) <<
D) <

2. State True or False.
i) A satic function can have access to only other static members (functions or variables) declared in the same class.
ii) A static member function can be called using the class name (instead of its objects)
A) True, True
B) True, False
C) False, True
D) False, False

3. Which of the following condition is true for an object used as a function argument?
i) A copy of the entire objects is passed to the function.
ii) Only the address of the object is transferred to the function.
A) Only i
B) Only ii
C) Both i and ii
D) None of them


4. …………… enable us to hide, inside the object, both the data fields and the methods that act on that data.
A) Encapsulation
B) Polymorphism
C) Inheritance
D) Overloading

5. Which of the following is/ are the characteristics of friend function.
A) It is not in the scope of the class to which it has been declared as friend.
B) It can invoke like a normal function without the help of any object.
C) Usually, it has the objects as arguments.
D) All of the above.

6. The dereferencing operator ………….. is used to access a member when we use pointers to both the object and the member.
A) ->*
B) .*
C) Any of the above
D) None of the above

7. A ………………. Is a class whose instances themselves are classes.
A) Subclass
B) Abstract Class
C) Meta Class
D) Object Class

8. The dereferencing operator ……… is used when the object itself is used width in the member pointer.
A) ->*
B) .*
C) Any of the above
D) None of the above

9. A constructor that accepts no parameters is called the ……………….
A) Paramless constructor
B) No parameter constructor
C) Default constructor
D) Argumentless constructor

10. Automatic initialization of object is carried out using a special member function called …………
A) Friend
B) Casting
C) Reference Parameter
D) Constructor

11. Which of the following characteristics of constructor are true.
i) They should be declared in the public section.
ii) They are invoked automatically when the objects are created.
iii) They do not have return type and void also.
iv) We cannot refer their address.
v) Constructors cannot virtual.
A) Only i, ii, iii and v
B) Only ii, iii, iv, and v
C) Only i, iii, iv and v
D) All i, ii, iii, iv and v

12. A ……………. takes a reference to an object of the same class as itself as an argument.
A) Reference constructor
B) Copy Constructor
C) Self Constructor
D) None of the above

13. State True or False
i) A destructor never takes any argument nor does it return any value.
ii) It releases memory space for future use.
A) True, True
B) True, False
C) False, True
D) False, False

14. Which of the following operates cannot be overloaded?
i) Size of operator (sizeof)            ii) Scope resolution Operator
iii) Conditional operator (?:)        iv) Assignment Operator (=)
A) i, ii, iii only
B) ii, iii, iv only
C) i, iii, iv only
D) all i, ii, iii, iv

15. …………. Is the process of creating new classes, called derived classes from existing classes called base class.
A) Inheritance
B) Encapsulation
C) Polymorphism
D) Overloading

16. State True or False.
i) While overloading operators new operator can be overloaded.
ii) The binary operator such as +, -, * and must explicitly return a value.
A) True, True
B) True, False
C) False, True
D) False, False

17. ………… function writes a string of text to a window.
A) cputs ()
B) put ()
C) gets ()
D) tputs ()

18. Which of the following condition (s) should satisfy the casting operator.
i) It must be a class member.
ii) It must not satisfy a return type.
iii) It must have any arguments.
iv) All of the above.

19. Find the Hierarchy of Data Types.
i) Long double   ii) Double             iii) Float                                iv) Long                                v) Int         vi) Char
A) 1-2-3-4-5-6
B) 1-3-2-4-5-6
C) 1-2-3-5-4-6
D) 1-2-4-3-5-6

20. ………….. function sets the fill pattern and color.
A) floodfill ()
B) setcolor()
C) setfillstyle()
D) fillstyle ()

 Answers:
1.       C) <<
2.       B) True, False
3.       C) Both i and ii
4.       A) Encapsulation
5.       D) All of the above.
6.       A) ->*
7.       C) Meta Class
8.       B) .*
9.       C) Default constructor
10.   D) Constructor
11.   D) All i, ii, iii, iv and v
12.   B) Copy Constructor
13.   A) True, True
14.   A) i, ii, iii only
15.   A) Inheritance
16.   C) False, True
17.   A) cputs ()
18.   iv) All of the above.
19.   A) 1-2-3-4-5-6
20.   C) setfillstyle()


You might also view the following related posts
  • Solved MCQ of C++ Set-1
For other more posts: Click Here
شارك المقال :
Tweet
✚

مقالات ذات صلة

التالي
المشاركةالتالية
السابق
المشاركة السابقة

تحويل كودإخفاء محول الأكواد الإبتساماتإخفاء

شكرا لمشاركتنا رأيك
Subscribe to: Post Comments (Atom)
  • Facebook
  • twitter
  • googleplus
  • youtube
  • linkedin

الأكثر زيارة

  • What is Information ?
    Information  can be defined as data that has been processed into a form that is meaningful to the recipient and is of real or perceived valu...
  • What is Information Technology?
    Definitions of  Information technology  ( IT ) It is a branch of engineering dealing with the use of computers and telecommunications equipm...
  • بالصور الفائزة بمسابقة ملكة جمال مصر 2017
    بالصور الفائزة بمسابقة ملكة جمال مصر 2017
    بالصور الفائزة بمسابقة ملكة جمال مصر 2017 لن تصدق من هي فرح صدقي ↓↓  لمشاهدة الصور والخبر كامل اضغط هنا  ↓↓ رابط المو...
  • Interview Questions on Stack and Queue in Data Structure set-2
    1) The queue in which the insertion takes place in the first position after of last element is a ...... A. priority B. dequeue C. circular D...
  • List of Top 65 Search Engine Submission Add URLs.
    List of Top 65 Search Engine Submission Add URLs.
    To get your site on the top ranking on the search engine results, Your site or URL must be indexed by Search Engines. For that you have to s...
  • List of Best Keyword Research Tools for Better SEO
    List of Best Keyword Research Tools for Better SEO
    Everyone needs to do keyword research work for the site before starting search engine optimization work as the first and most essential tas...
  • What are the different types of scheduling methods?
    Process scheduling is one way for a processor to handle n processes , by scheduling the execution process. Each process is executed one by ...
  • Solved MCQ on Database Backup and Recovery in DBMS set-1
    1) Which of the following is not a recovery technique? A. Deferred update B. Immediate update C. Two-phase commit D. Recovery management 2)C...
  • Solved MCQ on Distributed Database Transaction Management set-4
    1) Commit and rollback are related to .......... A. data integrity B. data consistency C. data sharing D. data security 2) The transaction w...
  • Solved MCQ on Fundamental of DBMS set-10
    1) Which of the following is not a characteristic of a relational database model? A. Table B. Tree like structure C. Complex logical relatio...

الأقسام

  • Artificial Intelligence(AI)
  • Backlinking
  • Basic IT
  • Best List
  • Blogging Tips
  • C
  • C#
  • C++
  • Computer Architecture
  • Computer Fundamental
  • Computer Security
  • Computer/IT Officer Exam
  • CSS
  • Data Mining and Warehousing
  • Data Recovery Tools
  • Data Structure
  • Database Management System
  • E-commerce
  • E-government
  • Internet & Web Designing
  • IT Law
  • IT Tips and Tricks
  • IT Tutorials
  • Java
  • JavaScript
  • Keyword Research Tools
  • MIS
  • Multiple Choice Question (MCQ)
  • Networking
  • Online Earning
  • Online IT Jobs
  • Operating System
  • Oracle Forms and Reports
  • Programming Guide
  • Programming Language
  • SEO
  • Social Networking Sites
  • Software Download
  • Software Engineering
  • System Analysis and Design
  • Top List
  • VB.Net
  • صحة
  • عجائب وغرائب

الأرشيف

  • ►  2017 (4)
    • ►  November (3)
    • ►  October (1)
  • ►  2016 (5)
    • ►  April (5)
  • ►  2015 (87)
    • ►  August (1)
    • ►  July (8)
    • ►  June (13)
    • ►  May (2)
    • ►  April (2)
    • ►  March (4)
    • ►  February (20)
    • ►  January (37)
  • ►  2014 (77)
    • ►  December (31)
    • ►  November (4)
    • ►  September (4)
    • ►  August (11)
    • ►  July (8)
    • ►  June (2)
    • ►  May (2)
    • ►  April (2)
    • ►  March (2)
    • ►  February (7)
    • ►  January (4)
  • ►  2013 (132)
    • ►  December (11)
    • ►  November (6)
    • ►  October (4)
    • ►  September (6)
    • ►  August (16)
    • ►  July (9)
    • ►  June (9)
    • ►  May (12)
    • ►  April (13)
    • ►  March (23)
    • ►  February (6)
    • ►  January (17)
  • ▼  2012 (59)
    • ▼  December (15)
      • How to generate massive web traffic through Social...
      • The 12 steps to become a successful blogger
      • The list of social bookmarking sites
      • List of High PR directory Submission Sites
      • List of sites to create shortcut URL for your bog ...
      • How to find the best online Jobs?
      • Solved MCQ of C set-1
      • Solved MCQ of Basic of IT Set-1
      • Solved MCQ of Java Set-1
      • MCQ of C++ with answer Set-2
      • Solved MCQ of C++ Set-1
      • Solved MCQ of Data Structure Set-1
      • Solved MCQ of Database Management System (DBMS) Se...
      • Solved MCQ of Database Management System (DBMS) Se...
      • Solved MCQ of Database Management System (DBMS) Se...
    • ►  November (20)
    • ►  October (21)
    • ►  September (3)

إنضم لنا

© 2017 أفكار جميع الحقوق محفوظة