CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
Search Posts SEARCH
Who's Online WHO'S
Log in LOG

Home: Perl Programming Help: Beginner:
Accessing an array



Aug 25, 2011, 2:15 AM

Post #1 of 2 (1193 views)
Accessing an array Can't Post

Two days ago, one friend makes me an answer:

What's the difference between accessing an array element with $items[$index] and @items[$index]?

And, i'm not sure.

Anyone can help me?


Aug 25, 2011, 5:14 AM

Post #2 of 2 (1182 views)
Re: [davidbj] Accessing an array [In reply to] Can't Post

The first is a scalar, the second, a slice. That is, it's a list of one element. See `perldoc perldata` and search for the section /Slices/.


I love Perl; it's the only language where you can bless your thingy.

Perl documentation is available at The list of standard modules and pragmatics is available in perlmodlib.

Get Markup Help. Please note the markup tag of "code".


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives