18.108 In trapezoid $A B C D$, $A B / / C D$, and $\angle A+\angle B=90^{\circ}$. If $A B=$ $a, C D=b$, and $E, F$ are the midpoints of $A B, C D$ respectively, then $E F$ equals
(A) $\frac{1}{2}(a+b)$.
(B) $\frac{1}{2}(a-b)$.
(C) $\sqrt{a^{2}+b^{2}}$.
(D) $\sqrt{a^{2}-b^{2}}$.
("Zu Chongzhi Cup" Junior High School Mathematics Invitational Competition, 1991)
[Solution] As shown in the figure, extend $A D, B C$ to intersect at $K$. Given $\angle A + \angle B = 90^{\circ}$, then $\angle A K B = 90^{\circ}$.

If we connect $K E$ intersecting $C D$ at $F^{\prime}$, then $F^{\prime}$ is also the midpoint of $C D$, i.e., it coincides with $F$ (by the properties of similar figures). By the property of the median to the hypotenuse in a right triangle, we have
$$
\begin{array}{l}
K E = \frac{1}{2} A B = \frac{1}{2} a, \\
K F = \frac{1}{2} C D = \frac{1}{2} b .
\end{array}
$$

Thus, $E F = K E - K F = \frac{1}{2}(a - b)$. Therefore, the answer is $(B)$.