> > if you're using the subject as his question, yes, but if you're > > using > > his example (below), no. (i.e. consider the case if kindergarden > > is -1.) > > You're right. > > I tried the following: > > > irb(main):012:0> kindergarden<0 ||=0 > SyntaxError: compile error > (irb):12: syntax error > kindergarden<0 ||=0 > ^ > from (irb):12 > Well, yeah; that was my point. =) His subject asked (or at least implies) about setting a var if it's not set, for which "||=" is perfect. But his example asks about setting something to 0 if it's not 0 already (< 0, i.e. negative), which is somewhat different. The code you used in irb doesn't quite make sense. (To me, anyway, and evidently to ruby as well.) "kindergarden<0" is a boolean expression, not a (var) name. __________________________________ Do you Yahoo!? SBC Yahoo! DSL - Now only $29.95 per month! http://sbc.yahoo.com