Problem

Source: INAMO 2019 P7

Tags: number theory



Determine all solutions of \[ x + y^2 = p^m \]\[ x^2 + y = p^n \]For $x,y,m,n$ positive integers and $p$ being a prime.