Problem

Source: Bulgaria MO Regional round 2024, 12.4

Tags: number theory



Find all pairs of positive integers $(n, k)$ such that all sufficiently large odd positive integers $m$ are representable as $$m=a_1^{n^2}+a_2^{(n+1)^2}+\ldots+a_k^{(n+k-1)^2}+a_{k+1}^{(n+k)^2}$$for some non-negative integers $a_1, a_2, \ldots, a_{k+1}$.