I have function defined this way:
def f1 (a, b, c = None, d = None): .....
How do I check that a, b are not equal
a
b
for key, value in locals().items(): if value is not None: check_attribute(key, value)
Though as others have said already, you can just check the arguments directly by name.