largest = None smallest = None while True : inp = raw_input ( 'enter a number' ) if inp == 'done' : break if len ( inp ) < 1 : break try : num = float ( inp ) except : print 'invalid input' continue if largest is None or num > largest: largest = num if smallest is None or num < smallest: smallest = num print 'max is' , largest print 'min is ' , smallest # your code goes here

bGFyZ2VzdCA9IE5vbmUKc21hbGxlc3QgPSBOb25lCndoaWxlIFRydWU6CglpbnAgPSByYXdfaW5wdXQgKCdlbnRlciBhIG51bWJlcicpCglpZiBpbnAgPT0gJ2RvbmUnOiBicmVhawoJaWYgbGVuKGlucCkgPCAxOiBicmVhawoJdHJ5OgoJCW51bSA9IGZsb2F0KGlucCkKCWV4Y2VwdDoKCQlwcmludCAnaW52YWxpZCBpbnB1dCcKCQljb250aW51ZQoJaWYgbGFyZ2VzdCBpcyBOb25lIG9yIG51bSA+IGxhcmdlc3Q6CgkJbGFyZ2VzdCA9IG51bQoJaWYgc21hbGxlc3QgaXMgTm9uZSBvciBudW0gPCBzbWFsbGVzdDoKCQlzbWFsbGVzdCA9IG51bQpwcmludCAnbWF4IGlzJywgbGFyZ2VzdApwcmludCAnbWluIGlzICcsIHNtYWxsZXN0IyB5b3VyIGNvZGUgZ29lcyBoZXJl