referencing and dereferencing in Perl is used for passing data structures to subroutines. for examples @example is an array to pass it to subroutine
@examples = ('perl', 'linux'); $reference_of_example = \@examples; #referencing your_sub($ref_example); sub your_sub { $ref = @_; print Dumper(@$ref); #@$ref is dereferencing array. }
In reply to Re: Passing a hash byreference to a subroutine
by karthiknix
in thread Passing a hash byreference to a subroutine
by edimusrex
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |