[Tutor] range() help

python at uni-code.com python at uni-code.com
Tue Apr 17 13:42:50 CEST 2007


Alright I'm a bit confused when looking at how range works.  I'm reading
lesson 4.3 in the python tutorial. http://docs.python.org/tut/node6.html

I came across this:

>>> range(-10, -100, -30)
[-10, -40, -70]

How come it prints on -40 or -70.

Does -70 come from -70 -> -100?

This is really confusing me.


More information about the Tutor mailing list