README first



  • Link: https://www.perl.org
    Starters Tutorial: https://learn.perl.org/first_steps/

    This section is for perl articles only.

    Notes:

    Similar to many programming/scripting languages perl starts numbering array indexes at zero

    Find the version of perl you have installed

    $  perl -v
    

    The start of the scripts will have
    #! /usr/bin/perl
    #! /usr/local/bin/perl
    or
    #! /usr/bin/env perl

    The /usr/bin/env looks for perl in your $PATH

    • Semicolons
      The semicolon is only needed if there is statement following, the statement you have, but usually one line scripts are not very useful, so generally, you need to separate your statements with a semicolon, except for the last statement.

    • There is a perl 6 but it is referred to as a separate language to perl 5.x, this section focuses on only perl 5.

    • Later versions of perl 5.10+ use the say statement to print things. It adds a newline for you automatically.

    • An undef value, when a variable has never been used (uninitialised), undef value make the variable act as a zero if a number or empty string, if a string.

    • The difference between a list and an array, the list is the data, and the array is variable holding the data.

    • For a concise list of perl built-in functions see: https://www.lightnetics.com/post/11063


Log in to reply
 

© Lightnetics 2024