--- Daniel Mester <[EMAIL PROTECTED]> wrote:
> Hi again,
>  for example i have a file like :
> zxcv  zxcv
> qwer  asdf
> bnmm  sdfgy
> 
> I need to split the sentences into a variables in list.
> So i do it in 2 stages:
> 1. Remove the \t form each pair:
> foreach (@list) { push(@temp, (split(/\t+/, $_))); }

Okay, this assumes the lines of the file have been read into @list as
individual elements?

> 2. Then i remove the \n between the strings:
> foreach (@temp) { push(@temp2, (split(/\n/, $-))); }

You completely lose me here.
What \n between strings?
 
> I am wondering - is there a way to do it in one turn? Must be, no?

I must've misunderstood what you are asking -- but have you tried:

 foreach (@list) { push(@temp, (split(/[\t\n]+/, $_))); }


__________________________________________________
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/

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

Reply via email to