in reply to Newbie to PERL removing text from array

You say you're putting "a file" into an array; I presume you mean the content of the file. But there are many ways of doing this. Are you going to store the entire content into a single array element? Each paragraph into a different element? Each line? Each word? Each character? Something else?

Assuming that what you are showing us are two different array elements, the following might work (untested):

foreach (@array) { s/^[^0-9]*[0-9]+\s+//; s/\.//g; s/Yes [0-9] //; }
But I've no idea how that works out of the rest of your file.

Replies are listed 'Best First'.
Re^2: Newbie to PERL removing text from array
by Anonymous Monk on Feb 15, 2012 at 05:47 UTC
    Hi, Thanks for the advice, I'm reading the contents of a file my ultimate goal is achieve a sanatzied version before merging with another file.