<font class="Apple-style-span" face="&#39;courier new&#39;, monospace">Here&#39;s a rookie question that stems from HtDP 29.3.2.</font><div><font class="Apple-style-span" face="&#39;courier new&#39;, monospace"><br></font></div>

<div><font class="Apple-style-span" face="&#39;courier new&#39;, monospace">The idea is to test an expression a number of times while timing it and compare to another version of the same function.  The expression finds a route in a vector (graph) from node 0 to node 4.  The way I would do this in C/Python is with a while loop, while the counter is not zero execute the expression (ignore return value), and wrap it in the timer.  In Racket I came up with:</font><div>

<font class="Apple-style-span" face="&#39;courier new&#39;, monospace"><br></font></div><div><div><font class="Apple-style-span" face="&#39;courier new&#39;, monospace">(time (for-each</font></div><div><font class="Apple-style-span" face="&#39;courier new&#39;, monospace">       (lambda (dest) (find-route 0 dest Graph))</font></div>

<div><font class="Apple-style-span" face="&#39;courier new&#39;, monospace">       (make-list 1000 4)))</font></div></div><div><font class="Apple-style-span" face="&#39;courier new&#39;, monospace"><br></font></div><div>
<font class="Apple-style-span" face="&#39;courier new&#39;, monospace">It seems unnecessarily tricky, but I couldn&#39;t think of a better way.  Am I missing a piece?  Does it only seem tricky because Racket is my first functional language.</font></div>

<div><font class="Apple-style-span" face="&#39;courier new&#39;, monospace"><br></font></div><div><font class="Apple-style-span" face="&#39;courier new&#39;, monospace">aTdHvAaNnKcSe</font></div><div><font class="Apple-style-span" face="&#39;courier new&#39;, monospace"><br>

</font></div><div><font class="Apple-style-span" face="&#39;courier new&#39;, monospace">^ actually unnecessarily tricky</font></div><div><font class="Apple-style-span" face="&#39;courier new&#39;, monospace"><br></font></div>

<div><font class="Apple-style-span" face="&#39;courier new&#39;, monospace">Luke</font></div><div><font class="Apple-style-span" face="&#39;courier new&#39;, monospace"><br></font></div><div><br></div></div>