download Mastguru Android App

Question Detail

How to define a destructor

  • X~() {}
  • X() {}~
  • X() ~{}
  • ~X() {}
Similar Questions :

1. All members of class have which access to its members

  • private
  • public
  • protected
  • depends

2. Constructor is

  • A class automatically called whenever a new object of this class is created
  • A class automatically called whenever a new object of this class is destroyed
  • A function automatically called whenever a new object of this class is created
  • A function automatically called whenever a new object of this class is destroyed

3. Which operator is used for comparing two variables

  • :=
  • =
  • =:
  • ==

4. What is the value of sizeof(char)

  • 1
  • 2
  • 4
  • 8

5. Meaning of STL

  • Standard Tree Library
  • Standard Term Library
  • Standard Template Library
  • None of above
Read more from - C++ Programming Questions Answers - Chapter 1
Post a comment