def main(): for x in range(10000, 0, -1): for y in range(9, 0, -1): L = range(1, y+1) cp = gmath.concatenated_product(x, L) if gmath.is_pandigital(cp) and len(str(cp)) == 9: return cp
def main(): result = [] for x in range(1, 60): for y in range(1, 2000): p = x*y z = str(x) + str(y) + str(p) if gmath.is_pandigital(z) and len(z) == 9 and p not in result: result.append(p) return sum(result)
def main(): for n in range(7654321, 1, -2): if gmath.is_pandigital(n) and gmath.is_prime(n): return n return None