While going through contest entries, we were bummed that we don't have more high-res JPGs (and laptops) to give out. Here are some highlights that didn't quite make finalists, but got the Honorable Mention award. For which the prize is an honorable mention in this article. This is the second in a three-part series.
Pete Bassett's "Petes Pants Calc" took the easy way out - rather than writing complicated C code, it shells out to VBScript for all arithmetic operations. (Petes Pants Calc)
Peter Gordon's "OMG Enterprise edition" is truly an enterprisey calculator. It's full of bitwise operations, gotos, and even uses an XML file for operation definitions. The code is absolutely worth looking at, but here's a minor highlight:
char valueminus48( char value ) { value = valueminusten( value ); value = valueminusten( value ); value = valueminusten( value ); value = valueminusten( value ); value = valueminusone( value ); value = valueminusone( value ); value = valueminusone( value ); value = valueminusone( value ); value = valueminusone( value ); value = valueminusone( value ); value = valueminusone( value ); value = valueminusone( value ); return value; }(OMG Enterprise edition)
Petr Kadlec knows how expensive addition and subtraction operations can be, and as such, caches all results. (SuperCaching Calculator (tm))
Rev. Johnny Healey was kind enough to include complete documentation for using his calculator:
OMGWTFCalc Documentation
How to enter the number 574
- Press the 5 button
- Press the 7 button
- Press the 4 button
And yes, he has instructions on entering all numbers from 0 through 999. (OMGWTFCalc)
Max Rabkin's description for his entry is better than anything I could come up with:
Calculator 2.0 is an enterprise-level client-side numerical productivity suite. It leverages proven technologies to provide a clear and user-friendly interface to a rich set of efficient and powerful components. It is powered by an XML database.
He also included a readme complete with a wooden table background. (Calculator 2.0 Notwork Edition)
Rembrand van Lakwijk's entry validates calculations by running each calculation several times in several different methods, then compares the results. It's hard to sum it up briefly, but taking a look at his code is highly recommended. (The Rembinator)