POV-Ray : Newsgroups : povray.off-topic : More random humous : Re: More random humous Server Time
7 Sep 2024 03:23:55 EDT (-0400)
  Re: More random humous  
From: Warp
Date: 7 Oct 2008 06:37:09
Message: <48eb3bd4@news.povray.org>
Orchid XP v8 <voi### [at] devnull> wrote:
> One of the nice properties of Haskell is that since a function can have 
> no side effects, you "only" need to check that it produces the correct 
> output for every valid input.

  Wait a minute... Exactly how do you create a random number generator in
Haskell?

  A random number generator function is, by definition, a function which
returns different values every time it's called (with the exact same
parameters, eg. none), and to do that it must remember its state from
the previous call.

  Not being able to create a RNG function would be rather restrictive in
many applications...

-- 
                                                          - Warp


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.