Function to find and print pair
def chkPair ( A , size , x ) : NEW_LINE INDENT for i in range ( 0 , size - 1 ) : NEW_LINE INDENT for j in range ( i + 1 , size ) : NEW_LINE INDENT if ( A [ i ] + A [ j ] == x ) : NEW_LINE INDENT print ( " Pair ▁ with ▁ a ▁ given ▁ sum ▁ " , x , " ▁ is ▁ ( " , A [ i ] , " , ▁ " , A [ j ] , " ) " ) NEW_LINE return True NEW_LINE DEDENT DEDENT DEDENT return False NEW_LINE DEDENT