Bogosort in ruby

Yesterday, I stumbled across the Bogosort sorting algorithm. The example implementations looked horrible so I tried to implement it in a short and readable way, in Ruby of course. Here is my first and only attempt of a Ruby Bogosort. # Use: ruby bogosort.rb a b c def sorted for i in (0..$array.length-2) return false […]

My favourite Ruby (on Rails) Books

I’ve read a couple of Ruby and Ruby on Rails books now and for those who wonder which book is right for them, I want to give recommendations. Ruby Books: My favourite ruby book is the “The Ruby Programming Language” from O’Reillys shelf. It is written by David Flanagan (author of Javascript, The Definitive Guide) […]

Ruby faster than Python and Perl!

When Pavel microbenchmarked every language he came across it turned out as expected, Ruby was the slowest language in all three micro tests. It was really embarrassing. I was curious if this was about to change in future versions of Ruby so I checked out the current Ruby 1.9 version from their svn repository svn […]