the triangles are all similar, because they have proportional sides and equal angles.
if you assume the smallest, equal part of side to be x
the biggest triangle has "5 parts" so BC=5x and BK has 3 parts so BK=3x .
since they're similar, ratio of their corresponding sides is constant or equal.
BK/BC=3/5
and AC=40
so JK = 40*3/5=24