o = Object.newo.instance_variable_set(:@x, 0) # Note required @ prefixo.instance_variable_get(:@x) # => 0o.instance_variable_defined?(:@x) # => true