Bas van Dijk wrote:
On Wed, Nov 5, 2008 at 12:43 AM, Bas van Dijk [EMAIL PROTECTED] wrote:
2008/11/5 Daryoush Mehrtash [EMAIL PROTECTED]:
Are there cases (function or list) where the result of foldl (or foldr)would
be different that foldl' (or foldr')?
Maybe this wiki article I wrote some
Excerpts from daniel.is.fischer's message of Wed Nov 05 00:37:47 +0100 2008:
Am Mittwoch, 5. November 2008 00:08 schrieb Daryoush Mehrtash:
Are there cases (function or list) where the result of foldl (or
foldr)would be different that foldl' (or foldr')?
thanks,
daryoush
Simple
Lets assume we don't have undefined in the list, are there functions (or
properties in the function) that would cause foldl to have different results
than foldl'?
daryoush
On Tue, Nov 4, 2008 at 3:37 PM, Daniel Fischer [EMAIL PROTECTED]wrote:
Am Mittwoch, 5. November 2008 00:08 schrieb
On Wed, 2008-11-05 at 10:01 -0800, Daryoush Mehrtash wrote:
Lets assume we don't have undefined in the list, are there functions
(or properties in the function) that would cause foldl to have
different results than foldl'?
If the function is partial on some elements of the list.
(3 /), for
On Wed, 2008-11-05 at 10:01 -0800, Daryoush Mehrtash wrote:
Lets assume we don't have undefined in the list, are there functions
(or properties in the function) that would cause foldl to have
different results than foldl'?
The only difference in the definition of foldl and foldl' is a seq so
Are there cases (function or list) where the result of foldl (or foldr)would
be different that foldl' (or foldr')?
thanks,
daryoush
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe
On Tue, 2008-11-04 at 15:08 -0800, Daryoush Mehrtash wrote:
Are there cases (function or list) where the result of foldl (or
foldr)would be different that foldl' (or foldr')?
There is no foldr'. And yes, foldl and foldl' are different functions
and thus return different results on some
Am Mittwoch, 5. November 2008 00:08 schrieb Daryoush Mehrtash:
Are there cases (function or list) where the result of foldl (or
foldr)would be different that foldl' (or foldr')?
thanks,
daryoush
Simple example:
import Data.List
weird :: Int - Int - Int
weird _ 0 = 0
weird x y = x*y
list
2008/11/5 Daryoush Mehrtash [EMAIL PROTECTED]:
Are there cases (function or list) where the result of foldl (or foldr)would
be different that foldl' (or foldr')?
Maybe this wiki article I wrote some time ago will answer your question:
http://haskell.org/haskellwiki/Foldr_Foldl_Foldl'
regards,
On Wed, Nov 5, 2008 at 12:43 AM, Bas van Dijk [EMAIL PROTECTED] wrote:
2008/11/5 Daryoush Mehrtash [EMAIL PROTECTED]:
Are there cases (function or list) where the result of foldl (or foldr)would
be different that foldl' (or foldr')?
Maybe this wiki article I wrote some time ago will answer
10 matches
Mail list logo