# Understand the problem

Find all pairs of positive integers $(n,k)$ so that $(n+1)^k-1=n!$.

[/et_pb_text][et_pb_tabs active_tab_background_color="#0c71c3" inactive_tab_background_color="#000000" _builder_version="3.23.3" tab_text_color="#ffffff" tab_font="||||||||" background_color="#ffffff"][et_pb_tab title="Hint 0" _builder_version="3.23.3"]Do you really need a hint? Try it first!

[/et_pb_tab][et_pb_tab title="Hint 1" _builder_version="3.23.3"]Note that $n+1$ has to be a prime, because any proper prime divisor of $n+1$ would divide $n!$ too.[/et_pb_tab][et_pb_tab title="Hint 2" _builder_version="3.23.3"]Say $n+1=p$. Note that, for large enough $p$, both $\frac{p-1}{2}$ and $2$ are factors of $(p-1)!$. Thus, the factor $(p-1)$ occurs twice in the expansion of $(p-1)!$.[/et_pb_tab][et_pb_tab title="Hint 3" _builder_version="3.23.3"]Prove that, if $(p-1)^2|p^k-1$ then $p-1|k$.[/et_pb_tab][et_pb_tab title="Hint 4" _builder_version="3.23.3"]Hint 3 implies that $p-1\le k$. Hence $p^{p-1}-1\le p^k-1=(p-1)!$. This is obviously false. Hence, $p$ has to be small enough to avoid this situation. It is avoided precisely when $p\in\{2,3,5\}$. This corresponds to $n\in\{1,2,4\}$. The equations to be solved are $2^k=2, 3^k=3$ and $5^k=25$. Hence, the solutions are $\{(1,1),(2,1),(4,2)\}$.[/et_pb_tab][/et_pb_tabs][et_pb_text _builder_version="3.23.3" text_font="Raleway|300|||||||" text_text_color="#ffffff" header_font="Raleway|300|||||||" header_text_color="#e2e2e2" background_color="#0c71c3" border_radii="on|5px|5px|5px|5px" box_shadow_style="preset3" custom_margin="48px||48px" custom_padding="20px|20px|20px|20px"]