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


INTERVIEW QUESTIONS LANGUAGES PERL DETAILS
Question :
Explain the difference between "my" and "local" variable scope declarations. ?


Category Perl Interview Questions
Rating (3.6) By 9 users
Added on 7/19/2006
Views 1471
Rate it!
Answers:

The variables declared with my() are visible only within the scope of the block which names them. They are not visible outside of this block, not even in routines or blocks that it calls. local() variables, on the other hand, are visible to routines that are called from the block where they are declared. Neither is visible after the end (the final closing curly brace) of the block at all.





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 difference between "Use" and "require". In which case should "Use" be used and not "Require"?

View Answer
I have a variable named $objref which is defined in main package. I want to make it as a Object of Class XYZ. How could I do it?

View Answer
What's the significance of @ISA, @EXPORT @EXPORT_OK
%EXPORT_TAGS list & hashes in a perl package?
With example?

View Answer
How to Connect with SqlServer from perl and how to display database table info?

View Answer
what's the purpose of -w.strict,-T?




View Answer
Difference between for & foreach,exec & system?

View Answer
Where do you go for perl help?

View Answer
Name an instance you used in CPAN module?

View Answer
When do you not use Perl for a project?

View Answer
How do you connect to database in perl

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/6205/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.95