22. Given a cube $\left.A B C D A_{1} B_{1} C_{1} D_{1} *\right)$ with edge $a$, $K$ is the midpoint of edge $D D_{1}$. Find the angle and the distance between the lines $C K$ and $A_{1} D$.
22. If $M$ is the midpoint of $B B_{1}$, then $A_{1} M \| C K$. Therefore, the required angle is equal to the angle $M A_{1} D$. On the other hand, the plane $A_{1} D M$ is parallel to $C K$, so the distance between $C K$ and $A_{1} D$ is equal to the distance from point $K$ to the plane $A_{1} D M$. Let the required distance be $x$, and the required angle be $\varphi$. Then we have

$$
V_{A_{1} M D K}=\frac{1}{3} S_{A_{1} M D} x=\frac{1}{3} S_{A_{1} K D} a=\frac{a^{3}}{12}
$$

From this, $x=\frac{a^{3}}{4 S_{A_{1} M D}}$. Let's find the sides of $\triangle A_{1} M D$:

$$
\left|A_{1} D\right|=a \sqrt{2}, \quad\left|A_{1} M\right|=\frac{a \sqrt{5}}{2}, \quad|D M|=\frac{3}{2} a
$$

Using the cosine rule, we find $\cos \varphi=\frac{1}{\sqrt{10}}$; thus,

$$
S_{A_{1} M D}=\frac{3}{4} a^{2}, \quad x=\frac{a}{3}
$$

Answer: $\arccos \frac{1}{\sqrt{10}}, \frac{a}{3}$.