Created
February 20, 2019 01:29
-
-
Save abaldwin88/5595d1584d74d5af54e3f35bc60e8d0d to your computer and use it in GitHub Desktop.
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
NUMBER_OF_TRIALS = 100 | |
NUM_OF_CHARS = 43 | |
CHAR_LIST = ('a'..'z').to_a | |
SEARCH_TERMS = CHAR_LIST.map do |letter| | |
letter + '?' * (NUM_OF_CHARS - 1) | |
end | |
results = Hash.new { |h, k| h[k] = [] } | |
NUMBER_OF_TRIALS.times do |i| | |
SEARCH_TERMS.each do |term| | |
results[term] << benchmark_get(term) | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment