Last active
December 27, 2015 14:59
-
-
Save ktakashi/7344518 to your computer and use it in GitHub Desktop.
bench mark result
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
$ sash etc/tak-sash.scm | |
0.62803584 | |
$ ./bin/picrin.exe etc/tak.scm | |
1.404000 | |
$ gosh etc/tak-gosh.scm | |
;(time (f)) | |
; real 0.734 | |
; user 0.734 | |
; sys 0.000 | |
12 |
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
(import (scheme time)) | |
(define (time f) | |
(let ((start (current-jiffy))) | |
(f) | |
(inexact (/ (- (current-jiffy) start) | |
(jiffies-per-second))))) | |
(define (tak x y z) | |
(if (> x y) | |
(tak (tak (- x 1) y z) | |
(tak (- y 1) z x) | |
(tak (- z 1) x y)) | |
y)) | |
(define (f) | |
(tak 12 6 0)) | |
(write (time f)) | |
(newline) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment