ZS - Sort into ascending order.

Syntax:

ZS

Description:

ZS sorts a set of lines into ascending order, according to the ASCII collating sequence. If you do not specify an address, ZS does nothing. If you specify one address, ZS sets "." to that line but otherwise does nothing. If you specify two addresses, ZS sorts all the lines between and including the given lines. In this case, the first address must precede the second in the buffer.

Each line is considered an indivisible unit and comparison is done on a strict left-to-right basis. ZS sets "." to the last line of the sorted text. ZS sets the condition register FALSE if the lines sorted were all the same, and TRUE otherwise.

Because the sort algorithm used by ZS is not overly efficient, you should not use ZS to sort large files.

Copyright © 1998, Thinkage Ltd.