Hi,

I get the following results using criterium[1]:

user=> (bench (naive-into #{} (range 1e5)))
Evaluation count : 900 in 60 samples of 15 calls.
             Execution time mean : 70,659330 ms
    Execution time std-deviation : 2,605840 ms
   Execution time lower quantile : 67,538775 ms ( 2,5%)
   Execution time upper quantile : 76,753815 ms (97,5%)

Found 3 outliers in 60 samples (5,0000 %)
low-severe 2 (3,3333 %)
low-mild 1 (1,6667 %)
 Variance from outliers : 23,8033 % Variance is moderately inflated by 
outliers
nil
user=> (bench (into #{} (range 1e5)))
Evaluation count : 1920 in 60 samples of 32 calls.
             Execution time mean : 33,112019 ms
    Execution time std-deviation : 948,885993 us
   Execution time lower quantile : 32,009162 ms ( 2,5%)
   Execution time upper quantile : 35,352072 ms (97,5%)

Found 2 outliers in 60 samples (3,3333 %)
low-severe 2 (3,3333 %)
 Variance from outliers : 15,7858 % Variance is moderately inflated by 
outliers
nil
user=> (bench (naive-into [] (range 1e5)))
Evaluation count : 4080 in 60 samples of 68 calls.
             Execution time mean : 15,011771 ms
    Execution time std-deviation : 306,806771 us
   Execution time lower quantile : 14,747953 ms ( 2,5%)
   Execution time upper quantile : 15,569223 ms (97,5%)

Found 7 outliers in 60 samples (11,6667 %)
low-severe 5 (8,3333 %)
low-mild 2 (3,3333 %)
 Variance from outliers : 9,3765 % Variance is slightly inflated by outliers
nil
user=> (bench (into [] (range 1e5)))
Evaluation count : 7020 in 60 samples of 117 calls.
             Execution time mean : 8,734595 ms
    Execution time std-deviation : 189,758751 us
   Execution time lower quantile : 8,569084 ms ( 2,5%)
   Execution time upper quantile : 9,261335 ms (97,5%)

Found 11 outliers in 60 samples (18,3333 %)
low-severe 2 (3,3333 %)
low-mild 9 (15,0000 %)
 Variance from outliers : 9,4482 % Variance is slightly inflated by outliers
nil

The core into being always faster than the naive one. As expected.

Kind regards
Meikel

[1]: http://clojars.org/criterium

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to