Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: Re: Re: Re: Re: build array of geometry data

by CharlesClarkson (Curate)
on Feb 11, 2003 at 06:50 UTC ( #234330=note: print w/ replies, xml ) Need Help??


in reply to Re: Re: Re: Re: build array of geometry data
in thread build array of geometry data

my @nloops = join(',',@{$collection[0]});
and try
print @nloops[1]
OUT
[1,1,1,1,1]
but the correct should be

1

Actually, there is nothing in @nloops[1]. It's not defined. join returns a scalar. Setting a scalar to @nloops places the scalar in $nloop[0].

What you probably wanted to do is:

my @nloops = @{ $collection[0] };

Now @nloops contains a list of values. $nloops[0] now contains 1.




HTH,
Charles K. Clarkson
Clarkson Energy Homes, Inc.


Comment on Re: Re: Re: Re: Re: build array of geometry data
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://234330]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (9)
As of 2014-08-21 09:12 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (128 votes), past polls