<table cellspacing="0" cellpadding="0" border="0" ><tr><td valign="top" style="font: inherit;">Hi Lyndon,<br><br>Since the example immediately above the exercise used randomRIO, I assumed that randomRIO was to be used as part of the solution to the exercise.<br><br>http://en.wikibooks.org/wiki/Haskell/Understanding_monads/State<br><br>Also, it was the above mentioned example that introduced me to *liftM2*, about which I posted a question a couple of days ago (subject line: Heavy lift-ing).<br><br>The next topic on the wiki page is "Getting Rid of the IO" which seems to be the direction of your post. No doubt I'll have more questions as I plod on.<br><br>Thanks for your input,<br><br>Michael<br><br><br>--- On <b>Mon, 7/26/10, Lyndon Maydwell <i>&lt;maydwell@gmail.com&gt;</i></b> wrote:<br><blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px;"><br>From: Lyndon Maydwell &lt;maydwell@gmail.com&gt;<br>Subject: Re:
 [Haskell-cafe] Random this! ;-)<br>To: "michael rice" &lt;nowgate@yahoo.com&gt;<br>Cc: "Max Rabkin" &lt;max.rabkin@gmail.com&gt;, "Ozgur Akgun" &lt;ozgurakgun@gmail.com&gt;, haskell-cafe@haskell.org<br>Date: Monday, July 26, 2010, 8:29 AM<br><br><div class="plainMail">I find it useful to have a seed argument to nearly all random<br>functions rather than using ones with an IO signature. This way you<br>can speed up your program quite a bit and also make testing much<br>easier. I think that MonadRandom does this automatically too.<br></div></blockquote></td></tr></table><br>