in reply to What is the problem with this script as no output

I didn't quite understood what you're trying to do, as this didn't help. The error is the way you empty the arrays/hashes (undef), so instead of
undef %hash,@index,@a2;
maybe you should try:
undef %hash; undef @index; undef @a2;
which will make perl forget about those variables, or
%hash=(); @index=(); @a2=();
which will make perl empty the contents of those variables
Dodge This!

Replies are listed 'Best First'.
Re^2: Why output is appending in each file??
by Anonymous Monk on Jun 03, 2005 at 09:11 UTC
    Thank you very much for everyone. My problem has been solved with your suggestions.