Searching for: Variable Declaration in Ruby
Local Variable Declaration
Used to declare a variable outside of a class.
Class and Instance Variables
Used declare variables within a class. There are two main types: class variables, which have the same value across all class instances (i.e. static variables), and instance variables, which have different values for each object instance.
An array is a variable that holds multiple values, indicated by an index. Ruby arrays can contain mixed types.
Used to declare a variable whose value is not meant to be changed.
Next Page >