A subroutine is like a function ... called upon to excecute a task.
When we are defining a function we have to use sub keyword in front of function name.syntax: sub functionname { statement; }Example: if($a>0) { &fun(); } sub fun { print "hai"; }
Please Note: We keep on updating better answers to this site. Subscribe to our newsletter to get notified when better answer is posted.
Copyright ©2003-2009 CoolInterview.com, All Rights Reserved. Privacy Policy | Terms and Conditions Page URL: http://www.coolinterview.com/interview/6188/default.asp?cachecommand=bypass