in reply to Re: Varying Variable Names
in thread Varying Variable Names

This node falls below the community's minimum standard of quality and will not be displayed.

Replies are listed 'Best First'.
Re: Re: Re: Varying Variable Names
by blakem (Monsignor) on Oct 16, 2001 at 02:45 UTC
Re: Re: Re: Varying Variable Names
by pixel (Scribe) on Oct 16, 2001 at 12:23 UTC
    I don't want to use symbolic referencing,

    and

    I just want to create a number of arrays depending on the number of times I run through a loop

    are contradictory statements. What you are asking to do is symbolic referencing. That's what you call it when you use one variable in the name of another. Other have given you good pointers to why you shouldn't do that, but if you really insist in ignoring their advice you should read perlref, particularly the section on symbolic references. Should you decide to take all the good advice that you've been given and implement this using arrays of arrays, then you might find it interesting to read, perlreftut, perllol and perldsc.

    Also note that use strict explicitly bars the use of symbolic references. I assume that you're being careful and have use strict in your script. In order to use symbolic references, you'll need to put no strict 'refs' around the piece of code where you're "bending" the rules.

    Blessed Be
    The Pixel