class Integer

def teen_to_word(numbers)

Returns:
  • (String) - The word representation of the number.

Parameters:
  • numbers (Hash) -- A hash containing number words.
def teen_to_word(numbers)
  if self < 10
    digit_to_word(numbers)
  elsif self < 20
    numbers[:teens][self - 10]
  else
    tens_place_to_word(numbers)
  end
end