I am learning from a tutorial on an educational website. The problem is that the video is from 2009 (Ruby 1.8), and some of the information may be outdated.
The instructor says that you need to use both getter/setter methods to access instance variables but a simple test shows otherwise:
@noise = noise
carnivore = Carnivore.new
puts noise = "roar" #will output "roar"
puts noise = "roar"
This line has nothing to do with the previous lines - not with the class Carnivore, not with the instance carnivore. It creates a local variable noise (and prints it). Start experimenting with