im dealing with this algorithm for some time and i dont know how what to do …

```
function convertToRoman(num) {
var numbers = [1000, 900, 500, 400, 100, 90, 50, 40, 10, 9, 5, 4, 1];
var roman = ['M', 'CM', 'D', 'CD', 'C', 'XC', 'L', 'XL', 'X', 'IX', 'V', 'IV', 'I'];
var result = "";
for(var i = 0; i < numbers.length; i++) {
if(numbers[i] == num) {
result += roman[i];
}
}
return result;
}
convertToRoman(3);
```