Solution (source code)

= Solution

A set $C\subseteq\mathbb R^d$ is <convex> when every <line segment> between two of its points remains in the set: for every $x,y\in C$ and $0\leq t\leq1$,
$$
\boxed{tx+(1-t)y\in C}.
$$