Problem

Source: Romania National Olympiad 2023

Tags: number theory, sum of digits



Determine all natural numbers $m$ and $n$ such that \[ n \cdot (n + 1) = 3^m + s(n) + 1182, \] where $s(n)$ represents the sum of the digits of the natural number $n$.