On Thu, 22 Feb 2001, DaVinci wrote: > Hi. > > I want to get a Time instance without seconds (round minutes). I have > probed next class: > > class MyTime < Time > def initialize > super > self -= sec > end > end > > but it doesn't work. I get error: > > Can't change the value of self > > Is any form of doing this?. You could add a method to class Time: class Time def round_to_m self - sec end end t = Time.new p t p t.round_to_m David -- David Alan Black home: dblack / candle.superlink.net work: blackdav / shu.edu Web: http://pirate.shu.edu/~blackdav