0

Why constructor cannot be consider as a member function.

26th Nov 2017, 7:08 AM
Dheeraj Sharma
Dheeraj Sharma - avatar
2 Respostas
+ 5
constructor is called when you initialize the class, while member function called after you initialize the class if not static
26th Nov 2017, 7:10 AM
Momo Belia
Momo Belia - avatar
+ 1
Constructor executes when object is created.We don't need to call constructor to perform its execution.On other hand member method and member variable need to call them. :)
26th Nov 2017, 7:49 AM
Faisal Rahman
Faisal Rahman - avatar