Hi,
I think what you mean is this:
for(@foo){ print "$_\n" } # ie, $_ holds the element of @foo you're
currently looking at
you can also explicitly name it like so:
for my $element (@foo) { print "$element\n" }
hth,
Jos Boumans
> I am using a for like so:
>
> for(@targets) {
> ...stuff...
> }
>
> What variable can I use to specify the CURRENT target to operate on?
>
> for instance:
>
> for(@targets) {
> ...stuff...("VARIABLE THAT IS EQUAL TO THE CURRENT TARGET")
> }
- How do i set this? Tim Grossner
- Re: How do i set this? Jos I. Boumans
- Re: How do i set this? Tim Grossner
- Re: How do i set this? Anthony E.
