New course! Every coder should learn Generative AI!
Try a free lesson+ 1
You use a composed class when it depends on the base class.
Example:
A chess board cell, how can it bs useful on it's own?
It cannot, therefor it depends on the chessboard, yo be used by it, it depends on it.