类也是对象,语法糖衣的写法:例如定义一个方法 def test(val) @val=val end 可以写来 def test=(val)或test=val @val=val end 调用的时候可以test=10....