Let me start out by saying this is not a flame, or a personal attack. This is just me posting a link to some of the worst code I've seen in my life, which is pretty much the whole point of this site.
Okay let's just say there's this guy who wrote this "search engine" and he posted some of the code to his website. This code could hypothetically be found here.
It would be helpful to have some sort of search engine to search through the code for this search engine, because the code structure can best be described as a large bowl of spaghetti. One of the benefits of this coding style is that you get the speed of VB6 and the clarity of assembly language all rolled into one.
Some highlights:
1. No functions, but plenty of gotos and labels. All of the labels are given helpful names such as "line_13012".
2. A surprisingly large amount of comments, the majority of which are completely useless. Some of my favorites:
array_aaa(array_pos) = " " + Left(aaa, tt - 1) + " "
array_ooo(array_pos) = " " + Left(ooo, tt - 1) + " "
aaa = Mid(aaa, tt)
ooo = Mid(ooo, tt)
xxx = Mid(xxx, tt) 'january 21 2001
and
If III < 1 Then GoTo line_13628i 'should never happen
3. Not one, but two completely useless replacements for a boolean:
match_flag = "YES"
...
match_flag = "NO"
and (notice anything wrong with this one?)
If sscreen_saver = "Y" And sscreen_saver = "N" Then
If you listen closely while you read the code, you can almost hear Dijkstra weeping.
B
Best posts made by burnmp3s
-
Functions Considered Harmful
-
RE: The Secretive Hidden InterNet Censors
@SpectateSwamp said:
Anyway a couple days ago (2) a trapper friend of my friend
called Him after receiving a call from some Official...The Real WTF<font face="verdana, arial" size="2">™ is your weird capitalization system. Generally you shouldn't capitalize pronouns unless you are referring to some sort of deity.
</font>