in reply to TIMTOWTDI - a counter
use Tie::File; sub Counter ($) { my @array; my $o = tie @array, 'Tie::File', shift || return undef; $o->flock; $array[0]++; } [download]
jeffa