Click here to Skip to main content
15,884,237 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 this the case to select case? Pin
Alberto Biasiutti9-Sep-11 3:00
Alberto Biasiutti9-Sep-11 3:00 
GeneralRe: Is this the case to select case? Pin
V.9-Sep-11 3:05
professionalV.9-Sep-11 3:05 
GeneralRe: Is this the case to select case? Pin
Nagy Vilmos9-Sep-11 5:10
professionalNagy Vilmos9-Sep-11 5:10 
GeneralRe: Is this the case to select case? Pin
Alberto Biasiutti9-Sep-11 5:21
Alberto Biasiutti9-Sep-11 5:21 
GeneralRe: Is this the case to select case? Pin
OriginalGriff14-Sep-11 3:12
mveOriginalGriff14-Sep-11 3:12 
GeneralRe: Is this the case to select case? Pin
Nagy Vilmos14-Sep-11 3:39
professionalNagy Vilmos14-Sep-11 3:39 
GeneralNeeded a series of random numbers PinPopular
Bert Mitton8-Sep-11 3:22
professionalBert Mitton8-Sep-11 3:22 
GeneralRe: Needed a series of random numbers Pin
Nagy Vilmos8-Sep-11 3:29
professionalNagy Vilmos8-Sep-11 3:29 
I'm sure you know the err, but some other points:
0. If you need random, use at least two unrelated sources to seed the sequence. I use a combo of ticks from the clock and position of the mouse.
1. Within an application only ever instantiate a single randomiser and do it as the first step of the run.


Panic, Chaos, Destruction. My work here is done.
Drink. Get drunk. Fall over - P O'H
OK, I will win to day or my name isn't Ethel Crudacre! - DD Ethel Crudacre
I cannot live by bread alone. Bacon and ketchup are needed as well. - Trollslayer
Have a bit more patience with newbies. Of course some of them act dumb - they're often *students*, for heaven's sake - Terry Pratchett

GeneralRe: Needed a series of random numbers Pin
Bert Mitton8-Sep-11 3:35
professionalBert Mitton8-Sep-11 3:35 
GeneralRe: Needed a series of random numbers Pin
Matty2225-Sep-11 21:16
Matty2225-Sep-11 21:16 
GeneralRe: Needed a series of random numbers Pin
BobJanova8-Sep-11 4:27
BobJanova8-Sep-11 4:27 
GeneralRe: Needed a series of random numbers Pin
RCoate8-Sep-11 12:24
RCoate8-Sep-11 12:24 
GeneralRe: Needed a series of random numbers Pin
annathor8-Sep-11 22:50
annathor8-Sep-11 22:50 
GeneralRe: Needed a series of random numbers Pin
Allan Thomas10-Sep-11 0:49
Allan Thomas10-Sep-11 0:49 
GeneralRe: Needed a series of random numbers [modified] Pin
CDP180214-Sep-11 3:01
CDP180214-Sep-11 3:01 
GeneralRe: Needed a series of random numbers Pin
Bert Mitton14-Sep-11 3:07
professionalBert Mitton14-Sep-11 3:07 
GeneralRe: Needed a series of random numbers Pin
CDP180214-Sep-11 3:49
CDP180214-Sep-11 3:49 
GeneralRe: Needed a series of random numbers Pin
Bert Mitton14-Sep-11 4:04
professionalBert Mitton14-Sep-11 4:04 
GeneralMessage Removed Pin
21-Sep-11 7:04
professionalN_tro_P21-Sep-11 7:04 
GeneralRe: Needed a series of random numbers Pin
Bert Mitton22-Sep-11 3:08
professionalBert Mitton22-Sep-11 3:08 
GeneralRe: Needed a series of random numbers Pin
Luis D. Aguilar7-Oct-11 7:49
Luis D. Aguilar7-Oct-11 7:49 
GeneralCommenting code... Pin
Sander Rossel4-Sep-11 20:47
professionalSander Rossel4-Sep-11 20:47 
GeneralRe: Commenting code... Pin
Firo Atrum Ventus4-Sep-11 22:02
Firo Atrum Ventus4-Sep-11 22:02 
GeneralRe: Commenting code... Pin
Allan Thomas5-Sep-11 14:53
Allan Thomas5-Sep-11 14:53 
GeneralRe: Commenting code... Pin
Sander Rossel5-Sep-11 19:56
professionalSander Rossel5-Sep-11 19:56 

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.