4. In a regular 20-gon, four consecutive vertices $A, B, C$ and $D$ are marked. Inside it, a point $E$ is chosen such that $A E=D E$ and $\angle B E C=2 \angle C E D$. Find the angle $A E B$.
Answer: $39^{\circ}$ (in the 2nd variant: $36^{\circ}$).

Note that $ABCD$ is an isosceles trapezoid with angles $\angle ABC = \angle DBC = 180^{\circ} \cdot 18 / 20 = 162^{\circ}$. Point $E$ lies on the perpendicular bisector of the base $AC$, and therefore, triangle $BEC$ is isosceles. Draw the height $EH$ in it, and drop a perpendicular $CK$ from point $C$ to line $ED$. We have: $\angle CEH = \angle BEC / 2 = \angle CED$. Therefore, right triangles $CEN$ and $CEK$ are equal by the acute angle and hypotenuse. In particular, $CK = CH = DC / 2 = CD / 2$, so in the right triangle $CKD$, the angle $KDC$ is $30^{\circ}$. In quadrilateral $CDEH$, three angles are $30^{\circ}$, $162^{\circ}$, and $90^{\circ}$, so the last angle $HED$ is $78^{\circ}$. Finally, $\angle CEK = \angle HED / 2 = 39^{\circ}$, and $\angle AEB$ is the same.