Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

what is the difference between require and use in perl?

Answer Posted / vinoth_bksys

The differences are many and often subtle:

* use only expects a bareword, require can take a
bareword or an expression
* use is evaluated at compile-time, require at run-time
* use implicitly calls the import method of the module
being loaded, require does not
* use excepts arguments in addition to the bareword (to
be passed to import), require does not
* use does not behave like a function (i.e can't be
called with parens, can't be used in an expression, etc),
whereas require does

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to convert strings into an array in perl?

1062


Explain the meaning of subroutine?

1016


What is the importance of perl warnings?

1225


Which has the highest precedence, List or Terms? Explain?

952


Explain lexical variables.

997


What does `$result = f() .. g()' really return?

1297


Why we use CGI?

2589


What is subroutine in perl?

992


What is the difference between perl array and perl hash?

1172


List the data types that Perl can handle?

1119


Explain the use of 'my' keyword in perl?

1070


Why is it hard to call this function: sub y { "because" } ?

1011


What are the options that can be used to avoid logic errors in perl?

1005


How do I generate a list of all .html files in a directory?

1000


What does undef function in perl?

1001