hi...
all of  your problem will solve with split..
it is very powerful...
please see in...

split [ PATTERN [ , EXPR† [ , LIMIT ] ] ]
Splits a string into an array of strings, and returns it. If LIMIT is
specified, splits into at most that number of fields. If PATTERN is also
omitted, splits at the whitespace. If not in array context, returns number
of fields and splits to @_.
and in
http://www.perldoc.com/perl5.6/pod/func/split.html
bye.




  _________________________
              Best regards

      Try to always be hopefull

           www.iraninfocenter.net
            www.electronegar.com
                  www.sorna.net
   ____________________________
----- Original Message -----
From: "eventualdeath" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Sunday, November 04, 2001 09:51 AM
Subject: Can I use split to split existing array !


Hi,

I need some clarification :-

Q1)    Can I use the split function to split an existing array (with several
elements ) such as the example below.

Q2)    Could it be that the split function can only be used to split a
scalar (one element).

Q3)    Could someone explain to me the reason why @readagain return the
number 4, and $#readagain return 0.

@read = ("hi please", "help me", "on this" , "problem");
@readagain = split (/whatever/, @read);

print "What happened here, it return 4 =>", @readagain,"\n";

##########



Thanks





-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to