Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw

Re: Help with Text::ParseWords

by nardo (Friar)
on Oct 18, 2001 at 19:59 UTC ( #119716=note: print w/replies, xml ) Need Help??

in reply to Help with Text::ParseWords

In addition to the two corrections by others, your textfile.dat is not in a suitable format. You are telling quotewords that you want to use spaces as a delimiter, but your textfile.dat has records which aren't seperated by spaces "Leppala"01261907 does not have a space in it. "Saukville""WI" doesn't either which will result in you getting Leppala01261907 and SaukvilleWI as records.

Replies are listed 'Best First'.
Re: Re: Help with Text::ParseWords
by basicdez (Pilgrim) on Oct 18, 2001 at 20:01 UTC
    Thanks. I have resolved that problem and actually have it working now. For future reference though, do you have any suggestions on how to seperate "Leppala"01261907 or "Saukville""WI" If not though that is cool as I have it working properly now. peace dez L
      If you are unconcerned about escaped quotes ("George \"The Man\" Washington") a quick way would be to set $keep to 1
      &quotewords('\s+', 1, $_);
      and then split on quotes.

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (2)
As of 2022-05-16 18:29 GMT
Find Nodes?
    Voting Booth?
    Do you prefer to work remotely?

    Results (63 votes). Check out past polls.