use attr_reader and attr_accessor