in reply to Re: cut vs split (suggestions)
in thread cut vs split (suggestions)
I am Perl-illiterate, but:
how is 5 faster than 1?
And how possibly "index" / "substring" could be faster than smth. like:
Sorry if I missed the point.
how is 5 faster than 1?
And how possibly "index" / "substring" could be faster than smth. like:
--?char* cut(char* pStr, int col, char* delim=",") { // not a real-life code, all good assumptions here: int n = 0; while(*pStr++){ if(*pStr==*delim){ if(++n == col){ return until_next_one(++pStr, delim); } } } }
Sorry if I missed the point.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: cut vs split (and on usefullness of cat, too:-))
by cees (Curate) on Apr 18, 2005 at 17:52 UTC |
In Section
Seekers of Perl Wisdom