Saved Bookmarks
| 1. |
What are special variables? |
|
Answer» There are specific types of variables whose MEANINGS are predefined and have SPECIAL significance. They perform a specific function as and when required by the programmer. Most of these PERL special variables come with a long English-like naming convention. For example, Operating System Error variable $! which can be written as: $OS_ERROR. All the special variables available within Perl leverage punctuation CHARACTERS FOLLOWING the usual variable indicator such as at (@), dollar ($), or percent (%) sign, like $_. For example: foreach ('Karlos', 'Sue', 'Dee') { print($_); print(" \n "); } |
|