Variables4:48 with Jason Seifer
A class is composed of methods and variables. Variables can keep track of different states and values inside of a class. In this video, we'll modify our `Name` class to take a variable for the `title` attribute and see how that variable can be shared.
class Name def initialize(title) @title = title end def title @title end def first_name “Jason” end def middle_name “” end def last_name “Seifer” end end
You need to sign up for Treehouse in order to download course files.Sign up