By checking dimensions, ##k+n=m## so it's enough to check just one of those equalities.
We may assume that ##n>0## since for ##S^m\to S^n## to be surjective, the codomain ##S^n## needs to be connected, and it's not possible to have ##m=0.##
Case 1: ##n>1.## We examine the following part of the associated long exact sequence:
##\pi_{k+1}(S^m)\to\pi_{k+1}(S^n)\to\pi_k(S^k)\to\pi_k(S^m).## The outer groups are zero since ##\pi_i(S^j)=0## when ##0<i<j.## So, ##\pi_{k+1}(S^n)\cong\mathbb{Z}## and hence ##k+1\geq n.##
We now consider the following part of the same exact sequence:
##\pi_n(S^m)\to\pi_n(S^n)\to\pi_{n-1}(S^k)\to\pi_{n-1}(S^m).## The case ##n=m## is impossible because that would make ##k=0,## in which case ##S^m\to S^m## is a double cover, but ##n=m>1## so ##S^n## is simply connected. So, again the two outer groups vanish and ##\pi_{n-1}(S^k)\cong\mathbb{Z},## giving ##n-1\geq k.## Together with the above, this means ##k=n-1.##
Case 2: ##n=1.## Examine the tail end of the exact sequence: ##\pi_1(S^m)\to\pi_1(S^1)\to\pi_0(S^k)## (where ##\pi_0## isn't given a group structure but exactness still makes sense and is valid.) If ##m>1## then the image of ##\pi_1(S^m)\to\pi_1(S^1)## is trivial and cannot match the kernel of ##\pi_1(S^1)\to\pi_0(S^k)##, which is the whole ##\pi_1(S^1).## So ##m=1,## which forces ##k=0## and the triple ##(k,m,n)=(0,1,1)## satisfies the right equations.
It's been a while since I took algebraic topology but hopefully this is mostly right.