Trimble interview question

Asked to write psedo code for 3sum, triplet