Created
February 13, 2010 17:13
-
-
Save marcric/303565 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
puts '===========' | |
puts :ZigZag.object_id #=> 199098 | |
puts :ZigZag.object_id #=> 199098 | |
puts '===========' | |
puts "ZigZag".to_sym.object_id #=> 199098 | |
puts "ZigZag".to_sym.object_id #=> 199098 | |
puts '===========' | |
puts :ZigZag == :ZigZag | |
# We get this true due to just one comparision | |
puts '===========' | |
puts "ZigZag" == "ZigZag" | |
# We get this true due to six comparisions | |
puts '===========' | |
puts :ZigZag.to_s | |
puts '===========' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment