From 5a894e88ee0492faddb976107a4bc58c808c521d Mon Sep 17 00:00:00 2001 From: TiagoRG <35657250+TiagoRG@users.noreply.github.com> Date: Thu, 19 Jan 2023 14:15:29 +0000 Subject: [PATCH] FP: Extra3: Ex06 update --- 1ano/fp/extra3/ex06.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/1ano/fp/extra3/ex06.py b/1ano/fp/extra3/ex06.py index c6a43d0..e1c233d 100644 --- a/1ano/fp/extra3/ex06.py +++ b/1ano/fp/extra3/ex06.py @@ -1,2 +1,2 @@ -# Complete... -stocks2 = sorted(sorted(stocks, key=lambda stock: stock[4], reverse=True), key=lambda stock: stock[0]) \ No newline at end of file + # Complete... + stocks2 = sorted(stocks, key=lambda stock: (stock[0], -stock[4]))