Ruby Programming in 60 seconds. Class variables and instance variables. Instance variables in Ruby begin with a single @ sign. The value of an instance variable is different for each object created from a class. Here each cat object has a different name which is stored in the @name variable. A class variable begins with two @@ signs. The value of a class variable is shared by all objects created from the class. This video explains.
For more hints and tips be sure to subscribe to the Bitwise Courses YouTube channel: / bitwisecourses
For in-depth programming tutorials, see the Bitwise Courses web site: http://www.bitwisecourses.com/
Ruby For Beginners: learn Ruby programming from the ground up with our in-depth Ruby tutorials.
The music in this video was composed by Nic Croll. For more of Nic's music, visit: http://www.nicolascroll.com/