Historical Note

This page was migrated from the original p-nand-q.com site which was last updated in 2015. The content has been preserved exactly as it was, with only formatting updated for modern browsers. Over the coming days and weeks, the content will be reviewed and may be updated for accuracy and relevance. If you find any issues, please contact me.

Obfuscation

For reasons that probably only a good psycho-analyst can explain, I've spend considerable time of my life writing obfuscated code. I have two favourites in particular that you'll see below:

Calculating PI to an arbitrary number of digits

Inspired by the original in Intercal, I've written programs that calculate PI to an arbitrary number of digits in C#, C/C++, Java, Objective-C and Python . And since I have planned to learn Haskell in 2014, expect a Haskell version of that any time soon :)

Quicksort

Another favourite of mine is abusing Quicksort to make it more readable. I have variants in C#, C/C++, Java and Python.

But wait, there is more

Spread throughout the depths of this website you'll find more fine examples of my interpretation of programming best-practices

And a couple of more things, but finding those is left as an exercise for the reader...