This looks a lot nicer than its c counterpart, in my opinion.
I suppose the next step will be to translate the C examples into their zig counterparts. This is also good dog food.