Sorry, I hadn't noticed you had replied.

I would like to achieve a structure "@ array" whose elements were other arrays. As I was reading this afternoon, this is achieved by references, that being scalars, can be elements of an array.

Correct.

So ... żI can by "map" to get from the output of the "fileparse" (a list of three scalar), an @array structure ($scalar1, $scalar2, ... $scalarn) where $scalarn is a reference to the list ($name, $path, $suffix)?

Close.

One can't create a reference to a list. You'll need to store $name, $path, $suffix in an array, and return a reference to that array. The three snippets I posted show ways of doing that.

So map will end up returning a list of references to arrays. Like subs, it cannot return an array, but you can store the list in an array.

I feel that I did not explained correctly.

Your post did not change my understanding of the question.


In reply to Re^5: Complex structures and function "map" by ikegami
in thread Complex structures and function "map" by nando

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.