blob: ba1061a6c9bc3603b6bfb49c4ba452b9e07a7635 [file] [log] [blame]
rjw6c1fd8f2022-11-30 14:33:01 +08001#!/usr/local/bin/perl
2$OUTPUT = $ARGV[0];
3shift(@ARGV);
4
5@INPUT = @ARGV;
6
7@new_output = sort @INPUT;
8
9if(-e $OUTPUT) {
10 open(W,">>$OUTPUT") or die "Cannot open $OUTPUT";
11} else {
12 open(W,">$OUTPUT") or die "Cannot open $OUTPUT";
13}
14
15foreach (@new_output) {
16 print W "$_ ";
17}
18print W "\n";
19close(W);
20
21
22
23