Appearance
A guard clause is an early condition placed at the beginning of a function/loop. It is typically used to avoid errors during execution.
def processUserInput(input): # Guard if input is invalid: return # Rest of the function # … return input