Pyrex: step in for loop

Luis P. Mendes luis_lupe2XXX at netvisaoXXX.pt
Thu May 26 18:11:50 EDT 2005


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1


| so it's
|
| for i in range(80000, 140000, 10000): ...
|
|     <mike

For what I've read, for i in range is slower than the other for
construct used by Pyrex:

for i from iMin <= i < iMax:

My question had to do with this new expression.  How can I introduce a
step there.

I am able to circumvent the problem passing a reduced range for i, let's
say iMin = 8, iMax = 14 when calling the pyrex module and then, after
the for statement:
i = i * 10000
and it works as it is intended to.


But, if there is a way to introduce the step  in the 'for i from iMin <=
i < iMax:' expression, I would like to know.

Thank you for your reply.

Luis
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFClkmlHn4UHCY8rB8RAlUqAKCxSEkEKVIcoshTwmL7GQNK6d/j0wCgoC67
jOhuXQpnDt23SEAM9huKTQA=
=8XO0
-----END PGP SIGNATURE-----



More information about the Python-list mailing list