Thread: Text Parser
View Single Post
  #13  
Old 05-08-2007, 03:11 AM
zokemon zokemon is offline
That one guy...
zokemon's Avatar
Join Date: Mar 2001
Location: Sonoma County, California
Posts: 2,925
zokemon is a jewel in the roughzokemon is a jewel in the rough
Send a message via ICQ to zokemon Send a message via AIM to zokemon Send a message via MSN to zokemon Send a message via Yahoo to zokemon
You guys must not realize that this:
for (i = 0; i < j; i++) {
func();
}
is simply:
i = 0;
while (i < j) {
func();
i++;
}

Also, checking every single letters seems to be A LOT of work. Much more effcient if you just found the first position of "@" and just moved like such. Hell, you could even tokenize("@") the whole thing and just do a for loop through the tokens (changing the mode of "variable" or "text" on every other token).
__________________
Do it with a DON!
Reply With Quote