in reply to Re: What is correct way to reference?
in thread What is correct way to reference?

    local $" = "\n";             # change list separator to a newline

    say ( ref $_ eq "ARRAY" ? "@$_" : $_ ) for ( $foo, $baz );

Wouldn't it be easier/quicker/clearer/more informative to use something like Data::Dumper::Dumper() (which is core) or Data::Dump::dd() (not core, but I like it a lot) to dump a scalar or reference and see exactly what its value or structure is? Why go through such specialized acrobatics?


Give a man a fish:  <%-{-{-{-<

Replies are listed 'Best First'.
Re^3: What is correct way to reference?
by 1nickt (Canon) on May 22, 2017 at 21:30 UTC

    Yes, of course! This is a completely contrived exercise to show $" ... simply for edification.

    The way forward always starts with a minimal test.