#!/usr/bin/perl -w

while( <> )
{
        chomp;
        $l = length($_);
        $t += $l;
        $n++;
        $f{$l}++;
}

@bylen = sort { $a <=> $b } keys %f;
print "n = $n, t = $t\n";
foreach $l (@bylen)
{
        $stars = "*" x int($f{$l}/180);
        print "$l: $stars\n"
}
