0xDE (11011110) wrote,

PADS updated to Python 3

PADS, my collection of Python algorithm implementations, has finally been updated to work under both Python 2 and Python 3. Most, but not all, of its modules have been tested under both version of Python.

Most of the code was already pretty close to working. The most frequent changes I needed to do: use next(iterator) instead of iterator.next(); avoid xrange, iteritems, and itervalues; use list(dict.items) for loops that change the dictionary; wrap arguments to print in parens.
Tags: python
  • Post a new comment

    Error

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 2 comments