Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: Regex copy and paste help

by aaron_baugher (Deacon)
on Aug 31, 2012 at 10:42 UTC ( #990978=note: print w/ replies, xml ) Need Help??


in reply to Regex copy and paste help

What have you tried so far? It seems to me the logic would work something like this:

read a line into an array, store it read the next line into an array if it only has one field preceded by whitespace append that field to the second field of the previous array else print out the stored array put this array into storage at the end, print the stored array

Coding that should be fairly simple. I don't know if the third line with only the first field is significant, so you may need to add some code to handle that too.

Aaron B.
Available for small or large Perl jobs; see my home node.


Comment on Re: Regex copy and paste help
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (6)
As of 2014-09-19 22:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (151 votes), past polls