Python's simplicity philosophy
bignose-hates-spam at and-benfinney-does-too.id.au
Thu Nov 20 02:15:15 CET 2003
On 19 Nov 2003 17:20:10 -0800, Paul Rubin wrote:
> "A.M. Kuchling" <amk at amk.ca> writes:
>> [the Unix command] uniq doesn't report an error if its input isn't
> Maybe it should. If its behavior on unsorted input isn't specified,
> you shouldn't assume it will act in any particular way.
The specification on the man page for GNU uniq seems clear on this:
Discard all but one of successive identical lines from INPUT
(or standard input), writing to OUTPUT (or standard output).
It doesn't care if the input is sorted or unsorted; it describes
behaviour on successive identical lines, not the total set of all lines.
\ "The Bermuda Triangle got tired of warm weather. It moved to |
`\ Alaska. Now Santa Claus is missing." -- Steven Wright |
Ben Finney <http://bignose.squidly.org/>
More information about the Python-list