[Haskell-cafe] Re: Simple but interesting (for me) problem

Neal Alexander relapse.dev at gmx.com
Wed Oct 21 14:34:00 EDT 2009

michael rice wrote:
> There's a thread on the plt-scheme list about creating a function of NO 
> arguments named NEXT that just returns the number of times it's been 
> called, a piece of cake in Scheme, but how would one do this in Haskell? 
> Would the best approach be to use a State monad?
> Michael
> ------------------------------------------------------------------------
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe

I think its more in the spirit of things things to have a function that 
produces an infinite list of values.

More information about the Haskell-Cafe mailing list