Click here to Skip to main content
15,900,108 members

The Weird and The Wonderful

   

The Weird and The Wonderful forum is a place to post Coding Horrors, Worst Practices, and the occasional flash of brilliance.

We all come across code that simply boggles the mind. Lazy kludges, embarrassing mistakes, horrid workarounds and developers just not quite getting it. And then somedays we come across - or write - the truly sublime.

Post your Best, your worst, and your most interesting. But please - no programming questions . This forum is purely for amusement and discussions on code snippets. All actual programming questions will be removed.

 
GeneralRe: Code that makes you go "hmmmm" Pin
dighn4-Nov-08 12:52
dighn4-Nov-08 12:52 
GeneralRe: Code that makes you go "hmmmm" Pin
Kevin McFarlane6-Nov-08 2:25
Kevin McFarlane6-Nov-08 2:25 
QuestionRe: Code that makes you go "hmmmm" Pin
Nathan Tuggy6-Nov-08 20:05
Nathan Tuggy6-Nov-08 20:05 
GeneralOMG a "Goto" PinPopular
CARPETBURNER22-Oct-08 22:50
CARPETBURNER22-Oct-08 22:50 
GeneralRe: OMG a "Goto" Pin
CPallini23-Oct-08 0:11
mveCPallini23-Oct-08 0:11 
GeneralRe: OMG a "Goto" Pin
Member 407229923-Oct-08 0:27
Member 407229923-Oct-08 0:27 
GeneralRe: OMG a "Goto" Pin
CPallini23-Oct-08 0:48
mveCPallini23-Oct-08 0:48 
GeneralRe: OMG a "Goto" Pin
BadKarma23-Oct-08 1:56
BadKarma23-Oct-08 1:56 
CPallini wrote:
BTW I didn't know C# has goto statement, is there a reason to have it in such a language?


A reason ? Maybe no, but you could need one if you use a switch.
switch(iData)
{
case 0:
case 1:
 // do stuff for 0 and 1
 break;
case 2:
 // do stuff for 2
 goto 3;
case 3:
 // do stuff for 2 and 3
 break;
}


Learn from the mistakes of others, you may not live long enough to make them all yourself.

GeneralRe: OMG a "Goto" Pin
MidwestLimey23-Oct-08 5:23
professionalMidwestLimey23-Oct-08 5:23 
GeneralRe: OMG a "Goto" Pin
VirtualVoid.NET23-Oct-08 6:13
VirtualVoid.NET23-Oct-08 6:13 
GeneralRe: OMG a "Goto" Pin
CPallini23-Oct-08 6:37
mveCPallini23-Oct-08 6:37 
GeneralRe: OMG a "Goto" Pin
VirtualVoid.NET23-Oct-08 6:44
VirtualVoid.NET23-Oct-08 6:44 
GeneralRe: OMG a "Goto" Pin
johannesnestler11-Nov-08 5:28
johannesnestler11-Nov-08 5:28 
GeneralRe: OMG a "Goto" Pin
Dan Neely23-Oct-08 2:16
Dan Neely23-Oct-08 2:16 
GeneralRe: OMG a "Goto" Pin
Super Lloyd24-Oct-08 0:57
Super Lloyd24-Oct-08 0:57 
GeneralRe: OMG a "Goto" Pin
CPallini24-Oct-08 0:59
mveCPallini24-Oct-08 0:59 
GeneralRe: OMG a "Goto" Pin
Rob Grainger24-Oct-08 1:43
Rob Grainger24-Oct-08 1:43 
GeneralRe: OMG a "Goto" Pin
CPallini24-Oct-08 1:57
mveCPallini24-Oct-08 1:57 
GeneralRe: OMG a "Goto" Pin
Rob Grainger25-Oct-08 18:10
Rob Grainger25-Oct-08 18:10 
GeneralRe: OMG a "Goto" Pin
CPallini25-Oct-08 22:14
mveCPallini25-Oct-08 22:14 
JokeRe: OMG a "Goto" Pin
Andrew Rissing24-Oct-08 4:09
Andrew Rissing24-Oct-08 4:09 
GeneralRe: OMG a "Goto" Pin
johannesnestler11-Nov-08 5:43
johannesnestler11-Nov-08 5:43 
GeneralRe: OMG a "Goto" Pin
Thomas Weller24-Oct-08 1:27
Thomas Weller24-Oct-08 1:27 
GeneralRe: OMG a "Goto" Pin
Super Lloyd24-Oct-08 1:42
Super Lloyd24-Oct-08 1:42 
GeneralRe: OMG a "Goto" Pin
Thomas Weller24-Oct-08 2:58
Thomas Weller24-Oct-08 2:58 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.