Answer the question
In order to leave comments, you need to log in
How to convert a string to a number in Ruby?
The question may be stupid, and it's easy to implement it yourself, but it's always better to use the ways of those who have already gone through it. :)
So, there are several lines: for example, "the eighth of March", "the eighth of March", "the eighth people". Is there a gem for ruby that can do at least:
"March 8th", "March 8th", "8 people",
and at the maximum:
"March 8th", "March 8th", "8th Human".
Thanks in advance!
Answer the question
In order to leave comments, you need to log in
put gem 'russian'
and then write
<%= "count #{Russian.p(count, "thing", "things", "things")} %>
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question