In the above example:
def initialize(side_length)
@side_length = side_length
end
@side_length = side_length is just an assignment that passes the available argument to the instance variable, in this case it is the same name as the argument.
However, these two values should not have the same name . This is usually called for readability / consistency. The same code could have been just as easy:
def initialize(side_length)
@muffin = side_length
end
, ( -, ). , .
, , , , , , , side_length @muffin .
SO > , - .
, !