in reply to Re: some forking help
in thread some forking help

You'll eat up a lot of memory by reading the file into an array, and there'll be a hit for the initial read. Going line by line is a little gentler, though it's hard to say if the memory re-use will perform better. If you run out of swap space, you'll definitely have trouble. I nearly always use while.