You can also watch this happen by uncommenting print on line 8:

def iterToHighNum(increment,high_
num):
    end_point = 0
    a = [i for i in range(0,increment)]
    while (end_point != high_num) == True:
        for integer in a:
            if integer != high_num:
                print "no match, integer = %i" % (integer)
                end_point += 1
            if end_point == high_num and integer != (high_num - 1):
                print 'match, integer = %i, high_num = %i' %
(integer,high_num)

        previous_increment = increment
        increment += increment
        a = [i for i in range(previous_increment,increment)]

#instance
increment = 10000
high_num = 1000000
iterToHighNum(increment,high_num)
_______________________________________________
Tutor maillist  -  [email protected]
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to