Determine all positive integers $N$ for which there exists a strictly increasing sequence of positive integers $s_{0}<s_{1}<s_{2}<\cdots$ satisfying the following properties:  
- the sequence $s_{1}-s_{0}, s_{2}-s_{1}, s_{3}-s_{2}, \ldots$ is periodic; and  
- $s_{s_{n}}-s_{s_{n-1}} \leq N<s_{1+s_{n}}-s_{s_{n-1}}$ for all positive integers $n$.
【 Answer. All $N$ such that $t^{2} \leq N<t^{2}+t$ for some positive integer $t$. Solution 1 (local). If $t^{2} \leq N<t^{2}+t$ then the sequence $s_{n}=t n+1$ satisfies both conditions. It remains to show that no other values of $N$ work.  Define $a_{n}:=s_{n}-s_{n-1}$, and let $p$ be the minimal period of $\left\{a_{n}\right\}$. For each $k \in \mathbb{Z}_{\geq 0}$, let $f(k)$ be the integer such that  $$ s_{f(k)}-s_{k} \leq N<s_{f(k)+1}-s_{k} $$  Note that $f\left(s_{n-1}\right)=s_{n}$ for all $n$. Since $\left\{a_{n}\right\}$ is periodic with period $p, f(k+p)=f(k)+p$ for all $k$, so $k \mapsto f(k)-k$ is periodic with period $p$. We also note that $f$ is nondecreasing: if $k<k^{\prime}$ but $f\left(k^{\prime}\right)<f(k)$ then  $$ N<s_{f\left(k^{\prime}\right)+1}-s_{k^{\prime}}<s_{f(k)}-s_{k} \leq N $$  which is absurd. We now claim that  $$ \max _{k}(f(k)-k)<p+\min _{k}(f(k)-k) $$  Indeed, if $f\left(k^{\prime}\right)-k^{\prime} \geq p+f(k)-k$ then we can shift $k$ and $k^{\prime}$ so that $0 \leq k-k^{\prime}<p$, and it follows that $k \leq k^{\prime} \leq f\left(k^{\prime}\right)<f(k)$, violating the fact that $f$ is nondecreasing. Therefore $\max _{k}(f(k)-k)<p+\min _{k}(f(k)-k)$, so $f(k)-k$ is uniquely determined by its value modulo $p$. In particular, since $a_{n}=f\left(s_{n-1}\right)-s_{n-1}, a_{n}$ is also uniquely determined by its value modulo $p$, so $\left\{a_{n} \bmod p\right\}$ also has minimal period $p$. Now work in $\mathbb{Z} / p \mathbb{Z}$ and consider the sequence $s_{0}, f\left(s_{0}\right), f\left(f\left(s_{0}\right)\right), \ldots$. This sequence must be eventually periodic; suppose it has minimal period $p^{\prime}$, which must be at most $p$. Then, since  $$ f^{n}\left(s_{0}\right)-f^{n-1}\left(s_{0}\right)=s_{n}-s_{n-1}=a_{n} $$  and $\left\{a_{n} \bmod p\right\}$ has minimal period $p$, we must have $p^{\prime}=p$. Therefore the directed graph $G$ on $\mathbb{Z} / p \mathbb{Z}$ given by the edges $k \rightarrow f(k)$ is simply a $p$-cycle, which implies that the map $k \mapsto f(k)$ is a bijection on $\mathbb{Z} / p \mathbb{Z}$. Therefore, $f(k+1) \neq f(k)$ for all $k$ (unless $p=1$, but in this case the following holds anyways), hence  $$ f(k)<f(k+1)<\cdots<f(k+p)=f(k)+p $$  This implies $f(k+1)=f(k)+1$ for all $k$, so $f(k)-k$ is constant, therefore $a_{n}=$ $f\left(s_{n-1}\right)-s_{n-1}$ is also constant. Let $a_{n} \equiv t$. It follows that $t^{2} \leq N<t^{2}+t$ as we wanted.