【入門】Common Lisp その6【質問よろず】
■ このスレッドは過去ログ倉庫に格納されています
0264デフォルトの名無しさん
2009/06/04(木) 05:38:14* (time (fact 45))
Evaluation took:
0.000 seconds of real time
0.000008 seconds of total run time (0.000007 user, 0.000001 system)
100.00% CPU
9,971 processor cycles
0 bytes consed
119622220865480194561963161495657715064383733760000000000
* (time (fact-cps 45))
Evaluation took:
0.000 seconds of real time
0.000010 seconds of total run time (0.000009 user, 0.000001 system)
100.00% CPU
13,546 processor cycles
4,080 bytes consed
119622220865480194561963161495657715064383733760000000000
と末尾再帰がたのfact-cpsの方が若干遅かったのは驚きました。
タイミングの問題ですかね?
■ このスレッドは過去ログ倉庫に格納されています