Explain the difference between die and exit in perl?
Answer / Mahfooz Ali
In Perl, both `my` and `local` are used to declare variables with a limited scope. The main difference lies in their lifetime:
* `my` variables are declared within the current lexical scope (subroutine or block). They retain their value across function calls.
* `local` variables are declared within the current dynamic scope (subroutine call). Their lifetime ends when the subroutine returns.
| Is This Answer Correct ? | 0 Yes | 0 No |
You want to connect to sql server through perl. How would you do that?
what is perl language?
Try pattern matching for the following: 1) 10.111.23.11 2) /root/abc/cde/fgg/ac.xml --> Get file name without extention. 3) /root/abc/ac.xml/fgg/ac.xml --> Get file name without extention. 4) What does "DIE" meant in PERL? 5) chomp 6) "This is saturday" --> Print the weekday number. 7) 11-2-2009 --> Print the name of the month. 8) Reverse the string without using func in C.
Comment on data types and variables in perl.
how to install a package in perl ????
Define say() function in perl?
What are the features of perl language?
What is a chomp() function in perl?
Write a script to reverse a string without using perl's built in functions?
Explain returning values from subroutines?
Explain substr function in perl?
Explain splicing of arrays?