Monday, April 14, 2008

Increment/decrement operator's in Ruby

Ruby has no pre/post increment/decrement operator. For instance, x++ or x-- will fail to parse. More importantly, ++x or --x will do nothing! In fact, they behave as multiple unary prefix operators: -x == ---x == -----x == ...... To increment a number, simply write x += 1.

Methods in a class

To find the pre defined methods defined for a class type

ri classname
in your command prompt

Example --- ri File ; ri String

Friday, April 11, 2008

Articles on Ruby's GC

http://whytheluckystiff.net/articles/theFullyUpturnedBin.html