Re: PIZZA time again :-)
Date: Sat, 3 Sep 2005 15:45:04 -0400
Message-ID: <yMGdnXQGj6CqYITeRVn-vg_at_comcast.com>
"mAsterdam" <mAsterdam_at_vrijdag.org> wrote in message
news:4319b070$0$11061$e4fe514c_at_news.xs4all.nl...
> mAsterdam wrote:
>> VC wrote:
>>> mAsterdam wrote:
> [snip]
>
>>>> merge_in_its_own_right merges a list of lists into a list. It
>>>>
>>>> - should not have assumptions about an
>>>> intrinsic order of the listed values.
>>>> - should preserve the order of the values
>>>> and fail if it can't.
>>> According to you specification the function should fail otherwise the
>>> function will behave as an ordinary (in the ML/Haskell sense) merge :
>>> 'if ordering(L1) == ordering(L2) merge otherwise fail'
>>
>> Yep.
> On second thought I'm not sure.
> Does 'ordering(L1) == ordering(L2)' in the ML/Haskell sense hold for
> L1 = [a, b, a, c]
> L2 = [a, a, c]
> ?
Since you define ordering by the position, then the ordering for L1 is:
{ (a,a), (a,b), (a,c), (b,a), (b,c)}
If L1 were [a,a,c,b] or [a,a,b,c], then it would be ordered. Received on Sat Sep 03 2005 - 21:45:04 CEST