Original post

New to this and trying to figure this out. I want to append a line number to the start of each line in a text file starting at for example 100 through however many lines are present in any given file:

LINE
LINE
LINE

Would become:

100 LINE
101 LINE
102 LINE

I’ve been trying for several hours. Can anyone take a look and offer a suggestion? I’ve tried all sorts of things that didn’t work. I’m back to the start again after several rewrites. I also think I’ve over complicated this whole thing and it could be done with less code. I just don’t know how.

https://pastebin.com/vmXrWnWp