Explain the difference between use and require?
Answer Posted / kush
Use :
1. The method is used only for the modules(only to include
.pm type file)
2. The included objects are varified at the time of compilation.
3. No Need to give file extension.
Require:
1. The method is used for both libraries and modules.
2. The included objects are varified at the run time.
3. Need to give file Extension.
| Is This Answer Correct ? | 38 Yes | 6 No |
Post New Answer View All Answers
How to create a package?
What is the difference between localtime() and gmtime() functions?
Explain splicing of arrays?
How does polymorphism work in perl?
What does cgi program store?
Explain ivalue?
How can arrays be tied?
Can inheritance be used in perl?
List the prefix dereferencer in Perl.
Explain chomp?
Perl uses single or double quotes to surround a zero or more characters. Are the single(' ') or double quotes (" ") identical?
How will you access an element of a perl array?
What are scalar data and scalar variables?
Explain USE and REQUIREMENT statements?
Demonstrate subroutines in perl with a simple example.