I've been working on this task (see screenshot). Here's my answer to it so far:var sum_pairs=function(ints, s){  //your code here  var ptr_1 = 0,      ptr_2 = 0,      i = 0,      j = 0,      len = ints.length,      j_min = len,      arr_sum = [];  for (i; i < len-1; i++){    for (j = i+1; j < len; j++){      if(ints[i] + ints[j] === s){        if (j < j_min){          j_min = j;          arr_sum = [parseInt(ints[i]), parseInt(ints[j])]        }      }    }  }return ( (arr_sum.length === 0)? undefined : arr_sum ); }However, while the tests all pass, it throws an STDERR about 'optimising the code':How might I be able to optimise my code further?
Codewars: Sum of Pairs
javascript;performance;time limit exceeded