diff options
author | Mattias Andrée <maandree@operamail.com> | 2012-08-01 03:33:30 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2012-08-01 03:33:30 +0200 |
commit | 70c27ca36f696b12012d7f47ac3071f747b95207 (patch) | |
tree | 7fd090244f918246f179becb767511fc8afc26fd /ponysaylinklist.pl | |
parent | e5b783e52858ae73d26c21464952323b9e3f320a (diff) | |
download | ponysay-70c27ca36f696b12012d7f47ac3071f747b95207.tar.gz ponysay-70c27ca36f696b12012d7f47ac3071f747b95207.tar.bz2 ponysay-70c27ca36f696b12012d7f47ac3071f747b95207.zip |
some edits
Diffstat (limited to 'ponysaylinklist.pl')
-rwxr-xr-x | ponysaylinklist.pl | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/ponysaylinklist.pl b/ponysaylinklist.pl deleted file mode 100755 index b7b4c6e..0000000 --- a/ponysaylinklist.pl +++ /dev/null @@ -1,36 +0,0 @@ -#!/usr/bin/perl - -# ponysaylist -# Prints a list of ponies in columns -# -# Licensed under WTFPL -# See COPYING for details - -# Author: Mattias Andrée, maandree@kth.se -# spider-mario - - -use strict; -use warnings; -use utf8; - -my %hash; - -{ - local @ARGV = @ARGV; - while ((my ($source, $target), @ARGV) = @ARGV) { - unless ($source eq $target) { - push @{$hash{$target}}, $source; - } - } -} - -while ((my ($source, $target), @ARGV) = @ARGV) { - if ($source eq $target) { - my @list = @{$hash{$source} // []}; - print $source; - print ' (', join(' ', @list), ')' if @list; - print "\n"; - } -} - |