Re: stable sorting

new topic     » goto parent     » topic index » view thread      » older message » newer message

Hi Matt, you wrote:

[...]

> try:
>
> function compare_mark (sequence a, sequence b)
>    integer c
>    -- Compare two sequences (records) according to MARK.
>    c = compare(a[MARK], b[MARK])
>    if c then
>       return c
>    end if
>    return compare(a[1],b[1])
> end function
>
>
> Matt Lewis

I spent some time, looking in some books for other sorting algorithms,
but didn't have the idea, to adapt the 'compare' function. sad
Thanks!

Best regards,
   Juergen

-- 
 /"\  ASCII ribbon campain  |
 \ /  against HTML in       |  Superstition brings bad luck.
  X   e-mail and news,      |
 / \  and unneeded MIME     |

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu