Skip to content

Instantly share code, notes, and snippets.

View mkonikowski's full-sized avatar

Mateusz Konikowski mkonikowski

View GitHub Profile
@mkonikowski
mkonikowski / gist:2308961
Created April 5, 2012 08:18 — forked from tgautier-silicon/gist:2305095
Le point sur l'interpolation
require 'benchmark'
n = 1000000
m = n.to_s
Benchmark.bm do |x|
x.report("assign single ") { n.times do; c = 'a string'; end}
x.report("assign double ") { n.times do; c = "a string"; end}
x.report("assign interp ") { n.times do; c = "a #{n} string"; end}
x.report("concat + single") { n.times do; 'a ' + n.to_s + ' string b ' + n.to_s + ' string'; end}
x.report("concat + double") { n.times do; "a " + n.to_s + " string b " + n.to_s + " string"; end}
@mkonikowski
mkonikowski / gist:2311838
Created April 5, 2012 15:08
global .gitconfig
[user]
name = Your Name
email = your@email
[push]
default = current
[color]
diff = auto
status = auto
branch = auto
interactive = auto