
12 Feb
2014
12 Feb
'14
12:19 p.m.
On Wed, Feb 12, 2014 at 03:10:21PM +0700, Kim-Ee Yeoh wrote:
On Wed, Feb 12, 2014 at 11:23 AM, Bryan Brady
wrote: ruler :: Stream Integer ruler = foldr1 interleaveStreams (map streamRepeat [0..])
This is an interesting solution.
I'd hazard to say that it's probably not the solution the author had in mind, so bonus points for novelty!
You're right that it's not the exact solution I had in mind, but I like it! I had in mind a more directly recursive version of ruler; I think proving the two solutions equivalent should not be too hard. -Brent