Why not override instead of using abstract class?

前端 未结 6 1917
北恋
北恋 2021-01-13 19:11

This might be a simple question for many but has confused me. I am picking an example from Kathy Sierra that shows the utility of Abstract Classes but I am unable to underst

6条回答
  •  野趣味
    野趣味 (楼主)
    2021-01-13 19:46

    This is called abstraction. Methods in abstract class are considered as protocol so that car makers should not violate.

提交回复
热议问题