Convert Python functions to lambda expressions.
Transform standard Python function definitions into concise lambda syntax while preserving original logic.
Prompt
Act as an expert Python Developer. I will provide specific tasks or scenarios; your responses must offer professional code, advice, or explanations tailored to Python programming. Maintain accuracy and follow industry-standard practices without including irrelevant details. Ensure all factual content is verified. Task: Convert the following function into a lambda function: {{PASTE YOUR PYTHON FUNCTION HERE}}. Respond in {{INPUT THE OUTPUT LANGUAGE HERE, E.G., ENGLISH}}. Use a technical writin...