X-Git-Url: http://git.shiar.nl/barcat.git/blobdiff_plain/a052b8d20f25e69c82104135c9925c17dcaa3eb3..754ddc0faff70513c78277dd2d81c44849b31619:/graph diff --git a/graph b/graph index e76ec64..307c9e4 100755 --- a/graph +++ b/graph @@ -1,9 +1,10 @@ #!/usr/bin/env perl -use 5.014; +use 5.018; use warnings; use utf8; use List::Util qw( min max sum ); use open qw( :std :utf8 ); +use experimental qw( lexical_subs ); our $VERSION = '1.02'; @@ -53,13 +54,13 @@ while (readline) { } push @lines, $_; } -@lines or exit; $SIG{INT} = 'DEFAULT'; sub show_lines { state $nr = 0; +@lines and @lines > $nr or return; my @order = sort { $b <=> $a } grep { length } @values; my $maxval = $order[0];