Cody Bable

Generation

generate functionFri, 19 May 2023

create a function for min and max of a number

def min_max(a, b): if a < b: return a, b else: return b, a def max(a, b): if a < b: return b else: return a def min(a, b): if a < b: return a else: return b min(1, 2), max(1, 2)

Questions about programming?Chat with your personal AI assistant