== Quote from retard (r...@tard.com.invalid)'s article > Wed, 25 Aug 2010 14:53:58 -0400, Steven Schveighoffer wrote: > > On Wed, 25 Aug 2010 14:37:33 -0400, Walter Bright > > <newshou...@digitalmars.com> wrote: > > > >> Steven Schveighoffer wrote: > >>>> Just goes to show how useful a profiler is. > >>> Yes, I'm glad you pushed me to do it. Looking forward to the fix. > >> > >> The two secrets to writing fast code are: > >> > >> 1. using a profiler > >> 2. looking at the assembler output of the compiler > >> > >> In my experience, programmers will go to astonishing lengths to avoid > >> doing those two... > > > > You mean like asking someone who reported low performance of your > > program on the newsgroup to do it for you? :) > He forgot: > 0. use a better algorithm (the big O notation matters, like in this case)
Yeah, but unless you use a profiler, how are you going to find those spots where N isn't as small as you thought it would be?