πŸ“Š C++
Q. Which of the following is true about destructors in C++?
  • (A) They must be explicitly called
  • (B) They have the same name as the class preceded by a tilde (~)
  • (C) They can have return types
  • (D) They can take arguments
πŸ’¬ Discuss
βœ… Correct Answer: (B) They have the same name as the class preceded by a tilde (~)

Explanation: Destructors in C++ have the same name as the class but are prefixed with a tilde (~).

Explanation by: Praveen Singh
Destructors in C++ have the same name as the class but are prefixed with a tilde (~).

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
97
Total Visits
πŸ“½οΈ
1 y ago
Published
πŸŽ–οΈ
Praveen Singh
Publisher
πŸ“ˆ
87%
Success Rate