#2005-03-13 04:52:08 1DAK9A-00036h-Du <= Kelly@australia.edu H=(67.19.219.66) [67.19.219.66] P=esmtp S=3260 id=N8vdA-68822V-5I@gee-wiz.com

open (FH, "< main.log");

@zeilen = <FH>;

foreach $zeile (@zeilen) {
  if ($zeile =~ /<=\s(.*?)\sH/) {
    $hash{$1}++;
  }
}


##  map (/<=\s(.*?)\sH/; $hash{$1}++) @zeilen;
   

@keys = sort {
  $hash{$a} <=> $hash{$b}
 } keys %hash;       # sort by value


foreach $key (@keys)
{
  printf("%-50s: %d \n", $key, $hash{$key} );  
  #print "$key".": ";
  #print "$hash{$key}\n";
}