I've tried, and searched and lost sleep over this one and I've nearly admitted defeat.
I have a text document with certain details listed which comes from another document which comes from a series of forms.
The document, let's say 'test.txt', has numerical values at lines 5, 11,17, 23 and so on so forth (just add 6 to the last number and you get the next). Each month the numbers in the file will be added together to give a total. Now there could be only a few numerical entries into the file, or there could be a hundred entries.
How can I add the numbers from test.txt lines 5, 11, 17, 23, 29 etc etc together to make a total without having to do the "$lines[5], 1, 4 " + $lines[11], 1, 4" etc etc.
I do hope someone can help me on this before I go demented.
Thanks!