Archive for February, 2008
Daily Used methods
.to_s
.to_i
.size
.class
+
.sort
.methods
Second Day in RUBY
In ruby methods name are intutive for example a Fixnum has .zero? (the meaning I guess is quite obviious).To get the Time/Day it is Time.new().To create the local time you pass the Time.local(year,month,day,hh,mm,ss,…) and there is a teritary operator (expression) ? 1:2 on true it will choose 1 else 2.print is just printing it without [...]
Read Full Post | Make a Comment ( None so far )Ruby – Question
What is this ARGF ??? and the grep method of it.
difference between clone & dup
difference between == , eql?, equal?
accessing the outer context of the block / nameless function (acting as a closure)
Ruby – OverView
Ruby is a interpretted language and is case sensitive.This a REPL language meaning read evaluate print and loop for the next statement.To run a program in ruby you have to call the interpreter first by saying ruby “location/name of the program” or you can start the shell irb which gets you to the ruby environment.To [...]
Read Full Post | Make a Comment ( None so far )