Favorite code snippet

http://en.cppreference.com/w/cpp/concept/LiteralType

I can stare at that all day and still be entertained. It just makes me so happy for some reason.

What is your favorite code snippet?
my favorite is probably the insertion sort from http://en.cppreference.com/w/cpp/algorithm/rotate

by the way, isocpp has a who-is-who page about some of the committee members, and they posted their favorite snippets: https://isocpp.org/wiki/faq/wg21
I do not have favorite code. However sometimes I find code which amuses me. Usually it is not something I would use in real programs, but some esoteric way to solve problem by abusing language. Latest one:
printf("%d\0\0\0Fizz\0Buzz\0FizzBuzz" + !(i % 3) * 5 + !(i % 5) * 10, i);
Topic archived. No new replies allowed.