Author: Francis Hwang
Converted to Pandora by: Julian I. Kamil
Original text: http://fhwang.net/blog/40.html
Introduction
Ruby is a subtle language. If you come to it after mastering another language like Perl or Java, it’s easy to write Ruby code that looks a lot like the code you used to write in your previous language. Now, writing code that way won’t take any longer than it would’ve taken in your previous language. But if you decide to become another disciple in the burgeoning Ruby cult, you’ll have a lot to gain by absorbing the various Ruby idioms. You’ll write clearer code in less time, and you’ll write less of it while accomplishing as much as you had before. I came to Ruby from Java, so here are a number of tips—some simple, some advanced—for the serious Java programmer who’s starting to become a serious Ruby programmer.
One documentation note: When people are writing about Ruby, they use ‘MyClass.method_name’ to refer to a class method, and ‘MyClass#method_name’ to refer to an instance method. You never actually call ‘MyClass#method_name’ in working Ruby code; it’s just a documentation convention.
Original format – Copyright © 2004-2006 Francis Hwang. All rights reserved.
Pandora format – Copyright © 2006 Julian I. Kamil. All rights reserved.
This text has been made available at The Ruby Bookshelf in the Pandora format by special permission from the author, Francis Hwang. Reproduction in whole or in part in any form or medium without express written permission by the original author is prohibited.
Pandora Powered ™


Pandora Powered ™
