Python lamba funcion - ghdrako/doc_snipets GitHub Wiki
Synax: Gorzej lambda args: expression
tasks.sort(key=lambda x: x['urgency'], reverse=True)
Unlike regular functions, which may return an object, lambda functions don’t return anything. When they do, you get a syntax error:
lambda x: return x * 2
# ERROR: SyntaxError: invalid syntax