prime checker and project euler 7