i am not understanding
How to approacjh this problem of pairs sum
In this question, you are given an array, and target value… and you have to print all the pairs whose sum results in the target values… Thus you can first sort the array and then can apply the bruteforce approach having two loops, i from 0 to n and j=i+1 to n, and simply check if ( ar[i]+ar[j]==target)
then simply print ar[i] and ar[j] values… This is the basic approach you have to use…