Sorry, another simple question
Fredrik Lundh
fredrik at pythonware.com
Thu May 20 03:49:41 EDT 1999
Joseph Kuan <jk94r at ecs.soton.ac.uk> wrote:
> How to derive the range function for a particular class?
>
> I tried with __range__ but it doesn't work.
range is a "plain old function" which returns a
list of integers.
if you want to create your own range function
to generate a sequence of your own type, you
should probably make that a module level
function.
</F>
More information about the Python-list
mailing list