Jun-14-2019, 04:38 PM

largest = None smallest = None while True: num = input("Enter a number: ") if num == "done": break try: fnum = float(num) except: print("Invalid input") continue if largest is None : largest = float(num) elif num > largest : largest = float(num) if smallest is None : smallest = float(num) elif num < smallest : smallest = float(num) print(num) print("Min:",smallest) print("Max:",largest) print("Maximum is",int(largest)) print("Minimum is",int(smallest))Can someone help point to where I have gone wrong with the logic please? Thanks!