In article <11df…@solani.org>,
Sebastian Barthel <nait…@freenet.de> wrote:
> I don't understand what this line
> > IF dummy$(i%) < dummy$(i%-1) THEN
> does. It compares two string - OK. But what is a string "bigger" than
> another ?
A string is 'bigger' than another if it alphabetically comes after the
other one. "Sebastian Barthel" is bigger than "Sebestian Bach"!
The point is that BASIC only looks at the ASCII value of characters for
determining the alphabetical flow. Therefore it puts 'Céline' after
'Coline', for example.
The other point was that OP's original routine takes 12.7 seconds to sort a
list of over 4000 lines and still has the 'Céline' problem, while a simple
BASIC program (okay, compiled) sorts 6000 lines without that problem in
about 3 seconds.
But of course, this simple program can be enhanced a lot further in many
ways, one of which is sorting pointers rather than strings, as you already
pointed out.
Paul