EF = EB + BF = 6 + 2 = 8
CD = AE - CF = 22 - 16 = 6
BC2 = BF2 + FC2
=> BC = $\sqrt{260}$
Similarly, AB = $\sqrt{520}$
And AC = 10
By the property of similar triangle, the length of the line joining the midpoints of the sides AB and BC is 5 (Option B)