Given, $$BD = 8 cm, AD = 4 cm, ∠ABC = 90^°$$ and $$BD⊥AC.$$
We know that, If a perpendicular is drawn from the vertex containing a right angle of a right triangle to the hypotenuse then the triangle on each side of the perpendicular are similar to each other and to the whole triangle.
So, $$ΔDBA∼ΔDCB $$ (A-A similarity)
$$BD/CD = AD/BD$$
[Since, triangles are similar, hence corresponding sides will be proportional]
$$BD^² = AD \times DC$$
$$(8)^² = 4 \times DC$$
$$64 = 4DC$$
$$DC = 64/4 $$
$$DC = 16 $$
In $$\triangle ADB $$, By Pythagoras theorem,
$$AB^2=BD^2+AD^2$$
$$AB=\sqrt{8^2+4^2}=\sqrt{100}=10 \ cm $$
Hence, the length of $$CD$$ is $$16$$ cm and $$AB$$ is $$10\ cm$$