in reply to Re: Re: Re: Re: Structure is more important than speed
in thread Which way is faster?
You are right. That is an assumption. Very often you can tell that it is true. Many optimizations add assumptions. Don't do them if the assumptions are wrong. Don't do them if you don't need the speed. Programmers should know this.if (defined(my $foo = $hash{$key})) { # ... }
That assumption was obviously right and I needed the speed. Adding that assumption seemed better than rewriting in C. Programmers sometimes must make such choices. That choice worked.
Do you feel enlightened about my reasoning?
|
|---|