\documentclass[11pt]{scrartcl}
\usepackage{evan}

\begin{document}
\title{EGMO 2022/4}
\subtitle{Evan Chen}
\author{Twitch Solves ISL}
\date{Episode 172}
\maketitle

\section*{Problem}
Given a positive integer $n \ge 2$, determine the largest positive integer $N$
for which there exist $N+1$ real numbers $a_0$, $a_1$, \dots, $a_N$ such that
\begin{enumerate}[(1)]
  \ii $a_0+a_1 = -\frac{1}{n}$, and
  \ii $(a_k+a_{k-1})(a_k+a_{k+1}) = a_{k-1}-a_{k+1}$ for $1 \le k \le N-1$.
\end{enumerate}



\section*{External Link}
\url{https://aops.com/community/p24921874}

\newpage

\section*{Solution}
The answer is $N  = n$.

Let $b_i \coloneq a_i + a_{i-1}$. Then the given condition is
\[ b_k b_{k+1} = b_k - b_{k+1}
  \implies b_{k+1} = \frac{b_k}{b_k+1}.  \]
So we can recursively compute every $b_i$:
\begin{align*}
  b_2 &= -\frac{1}{n-1} \\
  b_3 &= -\frac{1}{n-2} \\
  &\vdots \\
  b_n &= -1.
\end{align*}
We thus cannot have an $a_{n+1}$ in the sequence, because we'd get a contradiction.
Hence $N \le n$, and a construction by setting $a_0 = 0$
and recursively setting $a_i = -\frac{1}{n+1-i} - a_{i-1}$.

\end{document}
