Given:
\(
\begin{array}{l}
\angle BDC =90^{\circ} \\
\angle ABC =90^{\circ}
\end{array}
\)
Let \( \angle BCD = x ^{\circ} \)
Using angle sum property of a triangle in \( \triangle BDC , \angle DBC =90^{\circ}- x ^{\circ} \)
Also \( \angle ABD = x ^{\circ}\left(\angle D B C=90^{\circ}-x^{\circ}\right) \)
Using angle sum property of a triangle in \( \triangle ADB , \angle BAD =90^{\circ}- x ^{\circ} \)
Now considering \( \triangle BDC \) and \( \triangle ADB \)
\(
\begin{array}{l}
\angle BDC =\angle BDA \\
{\left[\because \angle BDC =\angle BDA =90^{\circ}\right]} \\
\angle DBC =\angle DAB \\
{\left[\because \angle DBC =\angle DAB =(90-x)^{\circ}\right]}
\end{array}
\)
So by AA
\( \triangle BDC \sim \triangle ADB \)
Hence \( \frac{ BD }{ CD }=\frac{ AD }{ BD } \)
\(
\frac{8}{C D}=\frac{4}{8}
\)
\(
C D=16
\)
Hence \( C D=16 cm \)