in reply to perl xml and array issue

print "Colors: " . (join ",", @{$products->{color}})."\n";

Replies are listed 'Best First'.
Re^2: perl xml and array issue
by dezboi (Initiate) on Nov 18, 2010 at 15:40 UTC
    So easy...and yet I couldn't figure this out on my own.

    This simple solution worked wonderfully!

    Thanks a ton, vroom
      look, $products->{colors} is actually a reference to an array. @{ } does dereferencing of a reference. I suggest you to spend 20 mins on perldoc perlreftut. It is small indeed.