```
var twoSum = function(numbers, target) {
var i=0,j=numbers.length-1;
while(i<j){
if(numbers[i]+numbers[j]>target){
j--;
}else if(numbers[i]+numbers[j]<target){
i++;
}else if(numbers[i]+numbers[j]==target){
return(Array(i+1,j+1));
}
}
};
```