How to convert 1 to “first”, 2 to “second”, and so on, in Ruby?

后端 未结 4 1322
慢半拍i
慢半拍i 2021-01-17 07:26

Is there a built-in method in Ruby to support this?

4条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2021-01-17 08:18

    How about Linguistics? Its not built in though. If you want built in , you have to set it up using hashes etc.. See here also for examples

提交回复
热议问题