Return the instance variables with Object's instance_variables: : instance_variables « Reflection « Ruby






Return the instance variables with Object's instance_variables:


$ship = "P"
@friend_1 = "M"
@friend_2 = "J"
bad_chap = "G"

p instance_variables

 








Related examples in the same category