dont know what I did, i just saw that it could be made into one line using arrow functions :V
const nums = ['zero', 'one', 'two', 'three', 'four', 'five', 'six', 'seven', 'eight', 'nine'] const digitToText = digit => nums[digit]
- const nums = ['zero', 'one', 'two', 'three', 'four', 'five', 'six', 'seven', 'eight', 'nine']
function digitToText(digit) {return nums[digit]}- const digitToText = digit => nums[digit]