perl array first element last element code example
Example 1: push to array perl
push @names, 'Charlie';
Example 2: last index array perl
print $#numbers_array;
# 4
print $numbers_array[$#numbers_array]; -between brackets-
# 62
push @names, 'Charlie';
print $#numbers_array;
# 4
print $numbers_array[$#numbers_array]; -between brackets-
# 62