Help for this page

Select Code to Download


  1. or download this
    my @IPMap = (
        [ "host_1", "192.168.1.1" ],
        [ "host_2", "192.168.1.2" ],
        [ "host_3", "192.168.1.3" ],
    );
    
  2. or download this
    my %IPMap = (
        host_1 => "192.168.1.1",
        host_2 => "192.168.1.2",
        host_3 => "192.168.1.3",
    );
    
  3. or download this
    use strict;
    use warnings;
    ...
    
    Dump $IPMapH;
    Dump $IPMapAoA;
    
  4. or download this
    $HASH1 = {
               host_1 => '192.168.1.1',
    ...
                  '192.168.1.3'
                ]
              ];