Posted in Ruby Find if a Variable is Defined in Ruby Binny V A December 3, 2007 Leave a Comment on Find if a Variable is Defined in Ruby This will let you find whether a variable is defined in ruby. if(defined? var_name) then print var_name + " is set" end Author: Binny V AA philosopher programmer who specializes in backend development and stoicism.