Classes can inherit from other classes using the < symbol.
<
class Animal def speak puts "Generic sound" end end class Dog < Animal def speak puts "Woof!" end end
Dog inherits from Animal and overrides the speak method.
Dog
Animal
speak