Fix integer division for Python 3 compat.