Function to check if a number is prime or not
def isPrime ( x ) : NEW_LINE INDENT if ( x <= 1 ) : NEW_LINE INDENT return False NEW_LINE DEDENT for i in range ( 2 , x + 1 ) : NEW_LINE INDENT if i * i > x : NEW_LINE INDENT break NEW_LINE DEDENT if ( x % i == 0 ) : NEW_LINE DEDENT DEDENT