About The Contest

The first ever Olympiad of Misguided Geeks contest at Worse Than Failure (or OMGWTF for short) is a new kind of programming contest. Readers are invited to be creative with devising a calculator with the craziest code they can write. One lucky and potentially insane winner will get either a brand new MacBook Pro or comparable Sony VAIO laptop.

Navigation

Advertisements

Entry #100253: Terry's Calculator

by Terry Lyons
The user interface was inspired by a post in the forums, someone wanted to see somebody do it and I couldn't resist the challenge.

It leaks like a sieve, but you won't find any new/malloc/etc and it only requires ~100MB of memory to run.

It uses a mouse hook, XML and memory mapped files for no good reason.

It's only guaranteed to work with maximum 6 digit numbers and by number I mean the Windows edit control definition of number (ie. non-negative integers, however it can output negative and floating point values). With numbers greater than 6 digits the behavior is undefined.

Like any good application that has to spend a lot of time doing calculations it uses a thread to do the calculations. Unlike a good application it ignores thread safety.

Download0 Comments