Beefy Boxes and Bandwidth Generously Provided by pair Networks RobOMonk
Just another Perl shrine
 
PerlMonks  

Re: array newbie...(sigh)

by BeernuT (Pilgrim)
on Mar 15, 2002 at 13:07 UTC ( [id://152036]=note: print w/replies, xml ) Need Help??

This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.


in reply to array newbie...(sigh)

might try doing
chomp @h;
as from those system calls will have extra \n on the end. That is if your wanting your output to be something like
0     0     0     0
If your wanting your output to be
0 0 0 0
then you might also try applying a substitute to the array
s/\s+/ /g for @h;
let me know if you need anymore help

-bn

Replies are listed 'Best First'.
Re: Re: array newbie...(sigh)
by ddrumguy (Acolyte) on Mar 15, 2002 at 15:24 UTC
    as from those system calls will have extra \n on the end. That is if your wanting your output to be something like 0 0 0 0 If your wanting your output to be 0 0 0 0 then you might also try applying a substitute to the array
    s/\s+/ /g for @h;
    how do i implement the above code - will i have to use an if statement or?? let me know if you need anymore help

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://152036]
help
Sections?
Information?
Find Nodes?
Leftovers?
    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.