Shilpa Arvind wrote: > Hi, > > In C programming language we have a function which looks like this: > > main(int argc, char *argv[ ]). > > Is there a equivalant function in Perl. I was looking at @ARGV but i > feel it does not behave the same way as the above function does. I > might be wrong.
@ARGV does not contain the program name as the first element. That is placed in $0 instead. Read the relevant sections in perldoc perlvar. Also read the section on "C Traps" in perldoc perltrap. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>