Shilpa Arvind wrote: > > Hi, Hello,
> In C programming language we have a function which looks like this: > > main(int argc, char *argv[ ]). Don't you mean: int main(int argc, char *argv[], char *env[]) C *requires* that all code must be in a function and that all programs have a function called 'main'. > 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. Perl, like many other programming languages, does not require that all code be in a function. As others have pointed out ( $0, @ARGV ) is the equivalent of C's *argv[] and %ENV for *env[] and exit() to return a value the way main does. John -- use Perl; program fulfillment -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>