Mental note: If you are doing two "filters" on some text, with one filter creating a list that the second filter then iterates over to find items, why not just do the second filter? (Bonehead)
I had written some code for one of my favourite Product Managers, and the perf on it bit. I poked and tried to optimize it, but to little avail. I got one query down from 29s to 20s. (the query involved running a couple of filtering regular expressions over some text and doing a number of WebRequests with the result). Regular Expressions fall into a painful area for me. I never learned grep, awk or perl as a child, so I find them amazingly difficult. Often in the past, relying on my knowing Darren Niemke's email address to save me. Even the Regulator (a tool I love from Roy) couldn't save me. Then, after not looking at the code for a few weeks and having Dan look at the pathetic thing I wrote, I realized, "Why am I doing two sets of RegEx, when the second one would do what the first one does?" I can be such an idiot at times.
OK, most of the time.
Print | posted on Saturday, September 17, 2005 9:39 AM