Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

Re: Error message "Use of uninit"

by Not_a_Number (Prior)
on Nov 21, 2011 at 19:33 UTC ( #939306=note: print w/replies, xml ) Need Help??

in reply to Error message "Use of uninit"

Since, at least in your posted snippet, you don't use the variables $tag or $freq, perhaps the best way of avoiding the warning would be to change the line

my($header,$tag,$freq)=split(' ', $line);


my ( $header, @rest ) = split ' ', $line;

Update (thanks AnomalousMonk): And of course you would have to change your output line to:

print $FILE2 "$header\t@rest\n";

Replies are listed 'Best First'.
Re^2: Error message "Use of uninit"
by bluray (Sexton) on Nov 21, 2011 at 22:08 UTC

    Thanks for the reply. Though it worked well in resolving the "uninitiated value", the output as I opened in spreadsheet have only 2 columns (2nd and 3rd column got crammed into the 2nd column separated by space).

    Anyway, I resolved the problem by changing the format of the heading line. Header,"Tag" "Frequency" was changed to "Header" "Tag" "Frequency"

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://939306]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (5)
As of 2017-12-16 12:15 GMT
Find Nodes?
    Voting Booth?
    What programming language do you hate the most?

    Results (450 votes). Check out past polls.