Ruby on Rails Discussions
Formatting integer (2 printed as 02)
rubyonrails-talk
eden_li
(eden li)
March 29, 2007, 2:55am
1
also,
i=61; "%02i:%02i" % [i / 60, i % 60]
=> "01:01"
Related topics
Topic
Replies
Views
Activity
Formatting integer (2 printed as 02)
rubyonrails-talk
0
115
March 28, 2007
Formatting integer (2 printed as 02)
rubyonrails-talk
0
135
March 28, 2007
preceding zero
rubyonrails-talk
8
212
September 28, 2009
how to format floating point number
rubyonrails-talk
0
135
September 11, 2006
RE: [Rails] Re: SEC to minutes
rubyonrails-talk
0
141
March 15, 2007