in reply to Whats quicker - passing along as variable to sub, or global var?

Be aware, these are gonna be pretty large strings... i.e thousands, if not tens of thousands worth of lines
Then you want to avoid copying the content. Since your second snippets copies the content twice, that will be the slowest.
  • Comment on Re: Whats quicker - passing along as variable to sub, or global var?