Hello, Codeforces!
Recently I stumbled upon a certain problem. Given n pairwise distinct positive integers (let's say all of them are less than or equal to 109), you're ought to find such smallest possible k that these numbers modulo k will still be pairwise distinct.
I'll be thankful if someone suggests a non-naive solution (i.e. w/o explicitly calculating all the pairwise differences) or provides some ideas to start with.