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
require 'benchmark' | |
ITERATIONS = 1000000 | |
Benchmark.bm(10) do |bench| | |
0.upto(40) do |n| | |
bench.report("chars: #{n}") do | |
string = "n"*n | |
ITERATIONS.times do | |
string + 'x' |
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
brew install rbenv | |
brew install ruby-build | |
brew install rbenv-vars | |
brew install readline | |
brew install ctags | |
echo 'eval "$(rbenv init - --no-rehash)"' >> ~/.bash_profile | |
exec $SHELL -i # reload the shell | |
CONFIGURE_OPTS="--disable-install-doc --with-readline-dir=$(brew --prefix readline)" rbenv install 1.9.3-p194 | |
rbenv global 1.9.3-p194 | |
gem install bundler rbenv-rehash git-up hitch gem-browse gem-ctags cheat awesome_print pry |