Problem

Source: Moscow mathematic olympiad 2022, Day 2 P11.5

Tags: number theory



Tanya wrote numbers in forms $n^7-1$ for $n=2,3,...$ and noticed that for $n=8$ she got number divisible by $337$. For what minimal $n$ did she get number divisible by $2022$?