[2.5.1] Building loop with some exceptions?

Gilles Ganault nospam at nospam.com
Fri Nov 7 03:06:08 EST 2008


On 04 Nov 2008 22:34:49 GMT, Steven D'Aprano
<steve at REMOVE-THIS-cybersource.com.au> wrote:
>for i in range(1, 100):
>    if i in (4, 34, 40, 44, 48, 54, 57, 67, 76, 83, 89):
>        continue
>    do_rest_of_processing

Thanks for the sample.



More information about the Python-list mailing list