export function twoSum(numbers: number[], target: number): number[] {
  let L = 0;
  let R = numbers.length - 1;

  while (L <= R) {
    const curSum = numbers[L] + numbers[R];
    if (curSum === target) return [L + 1, R + 1];
    curSum > target ? R-- : L++;
  }

  return [-1, -1];
};
