These articles are a random selection of write-ups I've done usually with the aim of helping me understand a new topic. With any luck they may even be useful to innocent bystanders.

C Pre-Processor Magic

C Pre-Processor Magic Implementing if-statements and iterators in CPP

The C Pre-Processor (CPP) is the somewhat basic macro system used by the C programming language to implement features such as #include and #define which allow very simple text-substitutions to be carried out at compile time. In this article we abuse the humble #define to implement if-statements and iteration.