Duff's Device Tom Duff Described as "the most dramatic use of fall-through yet seen in C", Duff's device is a remarkable algorithm that somehow marries two C structures in a surprising and efficient way. The result is both ugly and beautiful; disgusting and elegant.
The purpose of Duff's device is to transform data into an output stream, although it's more commonly used to confuse students and experienced programmers alike.