[Haskell-beginners] recursion problem.
Joel Neely
joel.neely at gmail.com
Sat Feb 7 13:25:32 UTC 2015
Brilliantly succinct answer!
And the programming task that started this thread is a nice (though
microscopic) illustration of the culture shock when our tidy, jewel-like
programming models come to grips with the messy, non-systematic nature of
many application domains.
Thanks for both.
-jn-
On Fri, Feb 6, 2015 at 10:59 PM, Karl Voelker <karl at karlv.net> wrote:
> On Fri, Feb 6, 2015, at 01:25 AM, Roelof Wobben wrote:
> > but now when I do toDigits 0 , I see [] as output where I was expected
> > [0]
>
> In our written notation, "0" is a special case: it's the only integer
> written with a leading zero. So don't be too surprised if your code
> requires a special case for it.
>
> -Karl
> _______________________________________________
> Beginners mailing list
> Beginners at haskell.org
> http://www.haskell.org/mailman/listinfo/beginners
>
--
Beauty of style and harmony and grace and good rhythm depend on simplicity.
- Plato
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/beginners/attachments/20150207/e23edcea/attachment.html>
More information about the Beginners
mailing list