Created
April 5, 2016 15:23
-
-
Save futoase/f38f73eecd94819f7251353883d58f4b to your computer and use it in GitHub Desktop.
test.rb
This file contains hidden or 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
require 'benchmark' | |
n = 10000000 | |
Benchmark.bm do |x| | |
x.report ('to_sym') { n.times do ; 'test'.to_sym end } | |
x.report ('to_s') { n.times do ; :test.to_s end } | |
end |
π π
to_sγ
γγγγγγγγγγγγγγγγγγγγγγγγγγγγγγγγγγγ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γ£γγγγγγγγγγγγγγγγγγγγγγγγγ
ζ©γ
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Ruby 2.3.0