Removed py2.7-only usage from CSV example.

`DictWriter.writeheader()` was introduced in Python 2.7 (thanks, @phoebebright). I've adjusted the example to use more ecumenical methods.