in reply to variable declaration shortcut question

lomSpace, Beyond your question, you seem to be doing some odd stuff.

  1. When you say my @maid_id = split(/_/, $komp_dir);, do you really mean to split $komp_dir? That variable is unchanging within both loops, and so should certainly not be reprocessed with every pass. Ditto for the other variables in the nested loop.
  2. The next line has another problem: my $maid = $fields[0]; Don't you mean my $maid = $maid_id[0];?
  3. Your braces in ${maid} are unnecessary and inconsistent with, say, $count.
  • Comment on Re: variable declaration shortcut question

Replies are listed 'Best First'.
Re^2: variable declaration shortcut question
by gone2015 (Deacon) on Feb 03, 2009 at 18:39 UTC

    Ah... no use strict... no likely to work.

Re^2: variable declaration shortcut question
by lomSpace (Scribe) on Feb 03, 2009 at 17:21 UTC
    Thanks for pointing that out. I am modifying that code.