Hi, Alexander

Your change produces the same sequence of 0s, 1s, and 2s.

mod n 2 == fromEnum (even n)

Michael


--- On Sat, 11/6/10, Alexander Solla <[email protected]> wrote:

From: Alexander Solla <[email protected]>
Subject: Re: [Haskell-cafe] Flagstone problem
To: 
Cc: "haskell-cafe Cafe" <[email protected]>
Date: Saturday, November 6, 2010, 1:40 PM


On Nov 6, 2010, at 4:03 AM, Brent Yorgey wrote:

> Doesn't make much sense to me.  The sum of binary digits in the binary
> representation of n will not be zero very often...

I think they mean "the sum (mod 2)" when they say "the sum of binary digits".  
That should be zero "half" the time.
_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe



      
_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to