Hi and thanks for the visit. If you're new here you may want to subscribe to my feed.
An interesting thread at Ruby_talk is ‘Your favorite bit of Ruby code.’
Setting aside time for learning HTML is beneficial to any web host.
John Carter from New Zealand has this interesting snippet of code:
# Ruby is Objects all the way down and open for extension...
class Integer
def factorial
return 1 if self <= 1
self * (self-1).factorial
end
end
puts 6.factorial
Technorati Tags: Ruby code
Posted by Satish TalimMy Sinatra eBook
The Introduction to Sinatra eBook is an easy-to-follow guide to everything on Sinatra. It is a complete step-by-step guide to quickly creating tiny web-applications and small services in Ruby. I focused entirely on practical advice with specific, actionable how-to tips, tools and techniques. Follow the easy steps and clear tactics to take action today.





{ 2 comments… read them below or add one }
My favorite is:
def debug(message)
if DEBUG == 1 and (block_given? ? yield : true )
puts “DEBUG: #{message}”
end
end
John’s example illustrates Ruby’s elegance and extensibility. My favorite is the file search – http://www.rubytips.org/about/