diff --git a/lisp/example1.lisp b/lisp/example1.lisp new file mode 100644 index 0000000..5b66647 --- /dev/null +++ b/lisp/example1.lisp @@ -0,0 +1,10 @@ +(defun b1 () + (let ((x 0)) + (dotimes (n 250000000) (incf x)) + x)) + +(defun b2 () + (let ((x 0)) + (declare (fixnum x)) + (dotimes (n 1000000000) (incf x)) + x)) \ No newline at end of file diff --git a/lisp/test.txt b/lisp/test.txt index 3d4e279..a77a59a 100644 --- a/lisp/test.txt +++ b/lisp/test.txt @@ -8,4 +8,9 @@ (time (dotimes (i 1000) (main-one '("69" "12" "1" "2" "11" "12" "1" "2" "11" "12" "1" "2" "11")))) +cmd +/usr/bin/time -v ./solution 477550 25000 19410 35300 1525 15800 25000 19410 35300 1525 15800 25000 19410 35300 1525 15800 25000 19410 35300 1525 15800 25000 19410 35300 1525 15800 + +/usr/bin/time -v ./solution3 477550 25000 1525 35300 19410 19410 1525 25000 15800 35300 25000 35300 1525 19410 15800 15800 25000 1525 15800 19410 35300 19410 25000 1525 35300 15800 +