Mostly a question to Jay McCarthy but I suppose could be interesting to others. 
Was going over his Reversing strings article. Somehow I get weird performance. 
Slowest solution turns out fastest, medium, fast and really fast are only 
marginally different.

Could anyone have a look https://github.com/vkz/warm-up
reverse-string.rkt has the solutions
test-reverse-string.rkt does the performance check
Testing it on 40'000 randomly generated strings 1000 chars each.

While we're at it, why do we garbage-collect thrice here?
let-values ([(as cpu real gc) (time-apply (λ () exp) empty)])
    (collect-garbage) (collect-garbage) (collect-garbage)

Thanks!
---
Vlad Kozin <vladilen.ko...@gmail.com>



____________________
  Racket Users list:
  http://lists.racket-lang.org/users

Reply via email to