Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!.POSTED!not-for-mail From: glen herrmannsfeldt Newsgroups: comp.lang.java.programmer Subject: Re: please coin a term for a lower order bug Date: Thu, 12 Jan 2012 01:45:34 +0000 (UTC) Organization: Aioe.org NNTP Server Lines: 23 Message-ID: References: <6pmrg7t72qbcdlmlmbf5sfldi32umji0ke@4ax.com> NNTP-Posting-Host: H0vc4U5LIRkRHNPyGCs2dA.user.speranza.aioe.org X-Complaints-To: abuse@aioe.org User-Agent: tin/1.9.6-20100522 ("Lochruan") (UNIX) (Linux/2.6.32-5-amd64 (x86_64)) X-Notice: Filtered by postfilter v. 0.8.2 Xref: x330-a1.tempe.blueboxinc.net comp.lang.java.programmer:11250 Roedy Green wrote: (snip on ways to make programs slow) > 2. stupidly slow. e.g. calling a method twice in succession for no > reason, using a bubble sort when a perfectly decent sort is built n > squared algorithms that can't possibly scale to what will be required. Some are not so obvious. Building long strings with strcat() in C is O(n**2). I once had to find and fix this in a program that put together megabytes one line at a time. > There is a snob attitude to DELIBERATELY waste resources, picking the > inefficient technique even when the programmer knows a better one that > is no more difficult. This is how we manage to make computers with > 3000 times the computer power less responsive that XTs. My favorite one to complain about is programs that read in a whole data set to process, when it could be done just as well one record, or small group of records, at a time. -- glen