what is attr_accessor in rails?
attr_accessor is a RUBY method, it has nothing to do with Rails. Anyway, attr_accessor automatically sets up getters and setters for those instance variables. That's it.