Click here to Skip to main content
15,890,185 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: Is silly bad? Pin
peterchen25-Oct-12 23:37
peterchen25-Oct-12 23:37 
GeneralRe: Is silly bad? Pin
Stefan_Lang26-Oct-12 0:56
Stefan_Lang26-Oct-12 0:56 
GeneralRe: Is silly bad? Pin
BobJanova26-Oct-12 1:01
BobJanova26-Oct-12 1:01 
GeneralRe: Is silly bad? Pin
Stefan_Lang26-Oct-12 1:53
Stefan_Lang26-Oct-12 1:53 
GeneralRe: Is silly bad? Pin
BobJanova26-Oct-12 2:34
BobJanova26-Oct-12 2:34 
GeneralRe: Is silly bad? Pin
Stefan_Lang26-Oct-12 3:51
Stefan_Lang26-Oct-12 3:51 
GeneralRe: Is silly bad? Pin
Paulo Zemek30-Oct-12 4:43
mvaPaulo Zemek30-Oct-12 4:43 
GeneralRe: Is silly bad? Pin
BlackMilan29-Oct-12 23:09
BlackMilan29-Oct-12 23:09 
Stefan_Lang wrote:
In any case pretty much all the previous programmers came from old style C and
weren't used to the type bool just yet.

Yes, there was no data type, but it was clearly defined: Zero was false, everything else true. So any data type could be a boolean.

This was very common for C programmers:
C++
char b = x > y;

Don't think, the Earth was a disc before .NET!

But I've seen something like this from many native VB programmers:
C#
bool b;
if (x > y)
    b = true;
else
    b = false;

GeneralRe: Is silly bad? Pin
Stefan_Lang30-Oct-12 0:13
Stefan_Lang30-Oct-12 0:13 
GeneralRe: Is silly bad? Pin
goodsport30-Oct-12 15:41
goodsport30-Oct-12 15:41 
GeneralRe: Is silly bad? Pin
Member 460889831-Oct-12 21:20
Member 460889831-Oct-12 21:20 
GeneralRe: Is silly bad? Pin
Paulo Zemek30-Oct-12 3:23
mvaPaulo Zemek30-Oct-12 3:23 
GeneralRe: Is silly bad? Pin
Fabio Franco30-Oct-12 10:43
professionalFabio Franco30-Oct-12 10:43 
GeneralRe: Is silly bad? Pin
lucien6431-Oct-12 5:13
professionallucien6431-Oct-12 5:13 
GeneralA very terrifying stored procedure: how can you solve this issue really ??? Pin
devenv.exe24-Oct-12 20:07
professionaldevenv.exe24-Oct-12 20:07 
GeneralRe: A very terrifying stored procedure: how can you solve this issue really ??? Pin
HaBiX24-Oct-12 20:29
HaBiX24-Oct-12 20:29 
GeneralRe: A very terrifying stored procedure: how can you solve this issue really ??? Pin
devenv.exe24-Oct-12 20:32
professionaldevenv.exe24-Oct-12 20:32 
GeneralRe: A very terrifying stored procedure: how can you solve this issue really ??? Pin
OriginalGriff24-Oct-12 21:32
mveOriginalGriff24-Oct-12 21:32 
GeneralRe: A very terrifying stored procedure: how can you solve this issue really ??? Pin
fjdiewornncalwe25-Oct-12 3:00
professionalfjdiewornncalwe25-Oct-12 3:00 
GeneralRe: A very terrifying stored procedure: how can you solve this issue really ??? Pin
BobJanova24-Oct-12 22:22
BobJanova24-Oct-12 22:22 
JokeRe: A very terrifying stored procedure: how can you solve this issue really ??? Pin
ZurdoDev25-Oct-12 2:03
professionalZurdoDev25-Oct-12 2:03 
GeneralRe: A very terrifying stored procedure: how can you solve this issue really ??? Pin
ENOTTY25-Oct-12 19:17
ENOTTY25-Oct-12 19:17 
GeneralRe: A very terrifying stored procedure: how can you solve this issue really ??? Pin
Brisingr Aerowing25-Oct-12 19:24
professionalBrisingr Aerowing25-Oct-12 19:24 
GeneralRe: A very terrifying stored procedure: how can you solve this issue really ??? Pin
Peter_in_278025-Oct-12 20:30
professionalPeter_in_278025-Oct-12 20:30 
GeneralRe: A very terrifying stored procedure: how can you solve this issue really ??? Pin
Gary Wheeler26-Oct-12 0:15
Gary Wheeler26-Oct-12 0:15 

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.