# your code goes here class Foo attr_accessor :num def initialize @num = 1 end def inc puts num.class puts num num = (num + 1) end end puts Foo.new.inc
Standard input is empty
Integer 1
prog.rb:10:in `inc': undefined method `+' for nil:NilClass (NoMethodError) from prog.rb:14:in `<main>'