Cambly interview question

What was the difference between composition and inheritance?