+ 3

Abstract functions can only appear in an abstract class.

What is the meaning of this?? Why is the use of abstract???🥴🥴🥴

9th Sep 2020, 10:22 AM
Sajib Adhikary
Sajib Adhikary - avatar
1 Answer
+ 1
An abstract class is a class that cannot be instantiated. It can only be inherited. It may contain abstract methods that must be implemented in any concrete subclass. It is an antipattern and should not be used in PHP. Use either traits or interfaces instead.
9th Sep 2020, 11:10 AM
Ore
Ore - avatar