Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: Batch to Perl translation (just 1 line, not the whole script)

by aitap (Deacon)
on Aug 07, 2012 at 20:50 UTC ( #986083=note: print w/replies, xml ) Need Help??


in reply to Batch to Perl translation (just 1 line, not the whole script)

open my $fh, ">>", $ARGV[0] || die "$0: $ARGV[0]: $!\n"; # open the file specified in the first argument in append mode print $fh q{BAYES; bayesClass=nameOfClassVariable; END}; # write the text; close $fh; # close the file;
See open, print, Quote and Quote like Operators, close for more information.
Sorry if my advice was wrong.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://986083]
help
Chatterbox?
[marto]: good morning all
[karlgoethebier]: good morning

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (7)
As of 2017-06-29 07:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How many monitors do you use while coding?















    Results (655 votes). Check out past polls.