I'm trying to add an attribute to the newly created method 'job', and then output the result but I don't seem to have my code right.
Can someone help me figure out how I can do this correctly?
I get this error code:
undefined method `job' for #<Context::Person:0x00000001ef0230 @name="Joe">
class Person attr_reader :name attr_writer :job def initialize(name) @name = name end end dude = Person.new("Joe") dude.job("hack") puts dude.name puts dude.job