Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: How to parse this file

by Caio (Acolyte)
on Oct 19, 2011 at 18:36 UTC ( #932459=note: print w/ replies, xml ) Need Help??


in reply to How to parse this file

Ok, I'm in a lazy mood to type code right now, but in the spirit of TIMTOWTDI, tell me what you guys think of the following idea:
Instead of doing a "constructive parsing" do a "destructive" one?

Pseudo-code would be something like:

open infile open outfile foreach (<inputfile>){ $_ =~ s/[letters]//g $_ =~ s/\s{2}//g #remove excess whitespace print $_ outfile } close infile close outfile


Just my 2cents anyway, what say you fellow monks?

UPDATE: Just entered and read tye's link, that should teach me to actualy read the link other monk's post answering questions before i rush into answering them myself. =/


Comment on Re: How to parse this file
Download Code
Replies are listed 'Oldest First'.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (14)
As of 2015-07-07 16:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (91 votes), past polls