Sorted Function With Lambda In Python