I appreciate all the help that I've already received but am running into one problem. I can find how to add something before a file with ascending numbers but not like this. I basically have a file that looks like this:
100
101
102
103
104
I need to add the following before each line with ascending numbers: line num0 file
So in the end, I would need the file to look like this:
line num0 file 100
line num1 file 101
line num2 file 102
line num3 file 103
line num4 file 104
Any help is appreciated.
P.S. Sed would be preferable but any programming language will suffice. Again, thanks.