<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-text-plain" wrap="true" graphical-quote="true"
style="font-family: -moz-fixed; font-size: 14px;" lang="x-western">
<pre wrap="">thx, hope I understand the standard library documentation now, but I still cannot find a random number generator - is there any libray that does this or do I have to write that myself?
I would prefer to keep it Scheme and not Racket as my course is meant to be Scheme and Prolog only.
<blockquote type="cite">
<div class="moz-text-plain" wrap="true" graphical-quote="true" style="font-family: -moz-fixed; font-size: 14px;" lang="x-western"><pre wrap="">Hi Erik,
On 2014-11-14 02:44:05 +0100, Erik Itter wrote:
</pre><blockquote type="cite" style="color: #000000;"><pre wrap="">shouldn't (remainder x y) be defined in scheme r6rs already?
</pre></blockquote><pre wrap="">If you look in the relevant section[1] of the R6RS standard libraries
document, it says that the `remainder` procedure is defined in the
`(rnrs r5rs (6))` library. So you have to do:
#!r6rs
(import (rnrs r5rs (6)))
Or you can use Racket, in which the `remainder` function is built-in to
the base language:
<a class="moz-txt-link-freetext" href="http://docs.racket-lang.org/reference/generic-numbers.html#%28def._%28%28quote._%7E23%7E25kernel%29._remainder%29%29">http://docs.racket-lang.org/reference/generic-numbers.html#%28def._%28%28quote._~23~25kernel%29._remainder%29%29</a>
[1]: <a class="moz-txt-link-freetext" href="http://www.r6rs.org/final/html/r6rs-lib/r6rs-lib-Z-H-20.html#node_idx_1292">http://www.r6rs.org/final/html/r6rs-lib/r6rs-lib-Z-H-20.html#node_idx_1292</a>
Cheers,
Asumu
</pre></div>
</blockquote></pre>
</div>
</body>
</html>