+ 3

Can abstract class be instantiated?

11th Jun 2017, 4:42 PM
soundarya s
soundarya s - avatar
6 ответов
+ 18
Nope. See Sololearn course.
11th Jun 2017, 4:49 PM
Igor Makarsky
Igor Makarsky - avatar
+ 3
Nope! since abstract class is nothing on its own. It is not complete. Abstract class is a skeleton structure i.e. an incomplete construct. So it can't be instantiated since it would defy the object oriented model.
11th Jun 2017, 5:07 PM
Ashish Dubey
Ashish Dubey - avatar
+ 1
Also , I think abstract class constructor is private. I am not sure but it could be one of the reasons.
11th Jun 2017, 5:10 PM
Ashish Dubey
Ashish Dubey - avatar
+ 1
no ,but the help of anonymous class we can instantiated.
30th Dec 2017, 4:27 AM
Viswanath T N
Viswanath T N - avatar
0
no they can't be..you can only create subclasses
11th Jun 2017, 6:11 PM
vivek suresh
vivek suresh - avatar
0
Since abstract class contain pure virtual function which needs to be defined before instantiation of that particular class other wise compile time error
14th Jun 2017, 6:21 PM
Huzaifah Punjani
Huzaifah Punjani - avatar