Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re^4: printing all elements of arrays

by beable (Friar)
on Jul 13, 2004 at 02:00 UTC ( [id://373810]=note: print w/replies, xml ) Need Help??


in reply to Re^3: printing all elements of arrays
in thread printing all elements of arrays

Here is another way to print the elements of an array on separate lines, using the $, variable (see perlvar:

#!/usr/bin/perl use strict; use warnings; my @array = (1..10); local $, = "\n"; print @array;

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (2)
As of 2024-04-19 19:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found