19. class Person
attr_accessor :name
end
class Student < Person
attr_accessor :school
end
class CollegeStudent < Student
attr_accessor :course
end
x = CollegeStudent.new
x.name = "John Doe"
x.school = "ABC University"
x.course = "Computer Science"
34. module Swimmer
def swim
puts "This #{self.class} is swimming"
end
end
class Duck
include Swimmer
end
class Person
include Swimmer
end
Duck.new.swim
Student.new.swim
52. Ruby Resources
main site
http://www.ruby-lang.org
tutorials
http://tryruby.org
http://ruby.learncodethehardway.org/
http://mislav.uniqpath.com/poignant-guide/
53. Rails Resources
main site
http://rubyonrails.org/
tutorials
http://ruby.railstutorial.org/
http://railsforzombies.org/
Windows Installer
http://railsinstaller.org/
54. Thank You For
Listening!
Philippine Ruby Users Group:
http://pinoyrb.org
https://groups.google.com/forum/#!forum/ruby-phil
me: http://bryanbibat.net | @bry_bibat