randint ( 0 , 100 ) function will generate odd or even number [ 1 , 100 ] with equal probability . If rand ( ) generates odd number , the function will return 1 else it will return 0
tmp = random . randint ( 1 , 100 ) NEW_LINE return tmp % 2 NEW_LINE