simple integer subclass

rantingrick rantingrick at
Tue Aug 3 05:36:48 CEST 2010

On Aug 2, 6:52 pm, Andreas Pfrengle <a.pfren... at> wrote:
> I'm trying to define a subclass of int called int1. An int1-object
> shall behave exactly like an int-object, with the only difference that
> the displayed value shall be value + 1 (it will be used to display
> array indices starting at 1 instead of 0)

Is zero based indexing that bad for you? I also think this is a very
bad idea unless you can offer a sensible use case -- for which i
cannot imagine.

More information about the Python-list mailing list