adplus-dvertising
frame-decoration

Question

How the constructors and destructors can be differentiated?

a.

Destructor have a return type but constructor doesn’t

b.

Destructors can’t be defined by the programmer, but constructors can be defined

c.

Destructors are preceded with a tilde (~) symbol, and constructor doesn’t

d.

Destructors are same as constructors in syntax

Answer: (c).Destructors are preceded with a tilde (~) symbol, and constructor doesn’t

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. How the constructors and destructors can be differentiated?