- Feature Articles
- CodeSOD
- Error'd
- Forums
-
Other Articles
- Random Article
- Other Series
- Alex's Soapbox
- Announcements
- Best of…
- Best of Email
- Best of the Sidebar
- Bring Your Own Code
- Coded Smorgasbord
- Mandatory Fun Day
- Off Topic
- Representative Line
- News Roundup
- Editor's Soapbox
- Software on the Rocks
- Souvenir Potpourri
- Sponsor Post
- Tales from the Interview
- The Daily WTF: Live
- Virtudyne
Admin
Not bad, nice and obscure.
captcha: slashbot. What brought me here a long time ago. (Almost)
Admin
What's the problem? Fixed-point math has a long and honorable history.
And there are only a few ways to divide-- shifting the divisor up or down until it can be subtracted is perfectly good. Your fancy Crays might use some fancier algorithms, but for a calculator limited by mouse speed- this routine is fast enough. But don't ask me if it's foolproof. Or works correctly for all inputs.
Admin
"a real, live, rotting codebase"
Something you can smell from a long way off. Nice entry!
Admin
Nice entry, but...did I miss something? (It is Monday after all...)
Wasn't the point of the contest to write new code that mimicked WTF code? Not just to submit buggy code that was over 10 years in the making?
And no, I didn't submit a calculator, so this isn't just sour grapes.
Admin
This is NOT real code. It's all made up. The author just brilliantly made it look that way.
Admin
I used to sit next to Steve-O.
I can vouch for you right now... that's not the only piece of WTF-code his company has. I submitted a few entries myself!
You should have seen their VB nightmare.
Whenever I see/hear the words "bContinue" I start to get a sick feeling in my stomach.
Admin
I think my favorite part is in CalcFunc.cpp:
else { /* Divisor is greater than dividend; shift divisor right until
whew good thing we're going to fix it later, for a second I didn't think there was anything that could handle this case, haha. Keep 'em coming!
Admin
I'm going to go address my obvious caffeine deficiency now...
o_O
Admin
The real WTF is that the text "ièce de résistance" is inexplicably in Arial (and with a <font> tag, too!)
Admin
The real WTF is that the bugs were fixed on Saturday / Sunday.
Admin
you have too much time uin your hands!.. I didn't noticed either
Admin
The Real WTF is the contest forums are gone.
Well, they were gone a minute ago
Admin
If you knew anything about my company, you'd know that was no WTF.
Admin
A "RISC processor that can't divide" is actually much more common than you might think: All ARM Processor Cores up to ARM9 belong to this category -- and these devices power almost every PDA and Smartphone out there, amongst uncountable other embedded systems. Even iPods use them (clocked at a mere 75 MHz) and do all the MP3/AAC decoding on them. Bottom line: Division is overrated :)
Admin
I’ll leave you with Stephen’s answer to a question I asked all finalists: would you replace calc.exe on Windows with your calculator?
It's sad that I'm now sure that I'm not a finalist :(
Admin
I think you meant "The author just brillantly made it look that way."
captcha: pirates. argh.
Admin
This is NOT real code. It's all made up. The author just brilliantly made it look that way.
No, he brilliantly made it look as if he brilliantly made it look that way.
Admin
Admin
Admin
Admin
There's one not even mentioned - I just compiled and ran the code and there's no way of getting a decimal point into the number entry box other than to divide two numbers together.
Admin
Same here. Hopefully, the non-finalist entries will get some sort of writeup on the front page instead of just a giant linkdump.
Admin
I second that, I thought my wtfery was tops!
Admin
Don't worry, I have several front-page articles planned for next week that discuss the non-finalists. There were so many incredible submissions. It was very hard to choose!
Admin
This is clearly not a WFT. This code has comments!
Admin
Well, this code is also not a WTF. Too bad I can't spell.
Admin
What Findeth Thou?
Admin
He might have been hoping for ninjas, in which case "argh" is correct.
Admin
I liked this one before I even looked at the code... just the screenshot made me flash back to "intro to (any language)" courses: the left-aligned number box, the blocky key layout w/ lots of wasted space, and the curios absence of a 'minus' key (there is a plus/minus key that looks like negation...?)
A+ for realism...
Admin
OK, found some bugs... Well... Two, in facts.
Admin
From King of Prussia, PA? Hey! Hi from Paoli!
Captcha: stinky. Just like the code. Ah.
Admin
Admin
Admin
Oooh that code just makes me itchy all over. Well done.
Admin
Of course I'm sure you're aware that if you write your AAC and MP3 decoders correctly you don't need a divide (the block codes can be recovered with a multiply, or even better rigged huffman decode tables)
Anyhow, lucky bugger actually gets routines to do divide :( I suppose that he gets log, exp & pow too!
Admin
Big deal. Everyone knows division is simply reciprocal multiplication.
Admin
Ooooops. What's a genuine serious non-WTF doing in a place like this? The Pentium belonged here but the skepticism was necessary.
This almost reminds me of one of my WTFs. I had successfully written microcode to implement a SQRT machine instruction using available registers, but my implementation of a DIV instruction spilled one value to the user's addressable stack. A friend kindly asked why I didn't shift new bits into reusable space in a register that I had just shifted other bits out of. Then she said my blush was really impressive. (This doesn't qualify as a genuine reminder of a WTF because I was an undergraduate, and the university wasn't even WFTU. Oh well.)
Admin
You soft pampered desktop developers. You really have no idea.
Not that long ago, I was programming devices with 64 bytes of RAM (it's not as bad as it sounds - they had 1K of ROM for the code). No divide? No multiply either. And no XOR. And a six entry stack.
Admin
There is if it aims to compete with the likes of Ho-Speed Printers...
Admin
Sounds like bliss to me.
Admin
It was. Simple straightforward programming to solve simple straightforward problems.
Admin
You mean you /wrote/ the WTFs yourself! Don't worry, we've ripped all your code out by now.
Admin
There was no "original Doom for DOS", the original was actually programmed on NeXTSTEP and then ported to DOS (and to everything else, from Linux to Irix to Solaris).
Admin
I thought ninjas would be more like "Hai yaah!"
Admin
cant download. why is broken