in reply to fast way to split and sum an input file

Using perl's index function instead of a regex or split should speed it up considerably.
  • Comment on Re: fast way to split and sum an input file

Replies are listed 'Best First'.
Re^2: fast way to split and sum an input file
by ikegami (Patriarch) on Aug 29, 2005 at 21:18 UTC

    I didn't think so. I tested to be sure:

    regexp: 509845 index_loop: 509845 Rate index_loop regexp index_loop 12.5/s -- -51% regexp 25.6/s 104% --