I am tasked with implementing a function that takes in an input x and tests Legendre\'s conjecture (there is at least one prime number in range [n^2, (n + 1)^2] for every po