Provide an alternative implementation of itertools.accumulate for Python < 3.3

Taken directly from official docs, will probably be quite a bit slower
than the native version, but there aren't many other options.

Fixes #8.