Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation

Re^6: hash to count words

by AnomalousMonk (Chancellor)
on Sep 17, 2012 at 19:52 UTC ( #994088=note: print w/replies, xml ) Need Help??

in reply to Re^5: hash to count words
in thread hash to count words

Now that I have that under control...

If 'that' refers to the lack code tags in your OP, the situation is still out of control. A  <code> tag is closed by a  </code> tag, not by a  </c> tag. Please see Markup in the Monastery. Please check the effects of your changes.

Printing to a file usually involves supplying an output file handle (see open) to the print statement. E.g.:
    my $filename = '';
    open my $fh_out, '>', $filename or die "opening '$filename': $!";
    my $something_to_output_to_file = your_process();
    print $fh_out "here is something for the file \n";
    print $fh_out $something_to_output_to_file;
    print $fh_out "that's all, folks! \n";
    close $fh_out or die "closing '$filename': $!";

Please consider re-reading the answers you have been given in this and related threads. Please consider using lexical filehandles (as in the example given above). See also autodie.

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (4)
As of 2017-11-19 06:12 GMT
Find Nodes?
    Voting Booth?
    In order to be able to say "I know Perl", you must have:

    Results (278 votes). Check out past polls.