Pergunta de entrevista da empresa Perforce Software

Target sum- An array is given and we have to return the pair of array elements which upon addition are equal to target value otherwise return -1