CoolInterview.com - World's Largest Collection of Interview Questions
Send Free SMS
 Interview Questions  
 Our Services  


INTERVIEW QUESTIONS LANGUAGES PERL DETAILS
Question :
what's is the use of 'require' and what does this mean?


Category Perl Interview Questions
Rating (0.0) By 0 users
Added on 7/19/2006
Views 885
Rate it!
Answers:

Require is a call to an external essential script or module, without which the current script/program will not proceed any further.



require function is used to load a seperate perl script or module in run time.If the file to be loaded is not in the directories listed in @INC array then full path of the perl file is to be passed in the require function .

ex . require "require.pl";
require "Mymodule.pm";
The location of perl file require.pl should be in directories listed in @INC.

otherwise give fullpath - require"/home/user/require.pl";

Once the perl file is loaded INC variable is updated with latest loaded perl file as key and its location as value .That's why before loading perl file require function checks if the file is already there in INC.If file is there then it'll not load the file.



 Posted by: sandeep    

Contact sandeep  Contact sandeep


If you have the better answer, then send it to us. We will display your answer after the approval.
Name :*
Email Id :*
Answer :*
Verification Code Code Image - Please contact webmaster if you have problems seeing this image code Not readable? Load New Code
Process Verification  Enter the above shown code:*
Inform me about updated answers to this question

   
Related Questions
View Answer
what is meant 'die' in a perl program?

View Answer
what is a DataHash(). What does it mean? and for what purpose it is used??

View Answer
What is CPAN ? What are the modules coming under this?




View Answer

Please Note: We keep on updating better answers to this site. Subscribe to our newsletter to get notified when better answer is posted.

Notify me when better answer is posted!
Email:

View ALL Perl Interview Questions

User Options
Sponsored Links


Copyright ©2003-2010 CoolInterview.com, All Rights Reserved.
Privacy Policy | Terms and Conditions
Page URL: http://www.coolinterview.com/interview/6182/default.asp?cachecommand=bypass


Download Yahoo Messenger | Placement Papers| FREE SMS | ASP .Net Tutorial | Web Hosting | Free SMS | Dedicated Servers | Joke of the Day

0.64