Arg!! Sorry, I really should have read the question more carefully.

while ($file = <dir/*.txt>) {
    open FH, $file or die $!;
    local $total;
    while (<FH>)  {
        $total += split /\S+/, $_ ; --$total;
    }
    print "In the file $file there are $total words\n";
}
--
print`$^Xdoc -qj`=~/"(.*)"/

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to