Print all pairs in an unsorted array with equal sum
Given an unsorted array A[]. The task is to print all unique pairs in the unsorted array with equal sum. Note: Print the result in the format as shown in the below examples. Examples: Input: A[] = { 6, 4, 12, 10, 22, 54, 32, 42, 21, 11} Output: Pairs : ( 4, 12) ( 6, 10) have sum : 16 Pairs : ( 10, 2