Abstract
- Classes :
can’t be instantiated.
- Methods :
can’t have any implementation,
need implementation from their children.
abstract class Shape {
protected int edges_num;
}
class Star extends Shape{
Star(int _edges) {
edges_num = _edges;
}
}
Previous slide
Next slide
Back to first slide
View graphic version