# basic scope and usage examples $globalVar = 5 CONSTANT = 15 nonGlobal = 10 def myFunction puts $globalVar puts CONSTANT begin puts nonGlobal rescue Exception => e puts e end # can't do this #CONSTANT = 12 end myFunction