What does happen in this code?

what actually happens when we give two arguemnts in by(while sorting)

my_data.sort_values(by=[“marks A”,“marks C”],ascending=true)

hey @ajaysiddartha ,
This means that first sort the values according to , marks A and once it is done , then keeping in mind the order of marks A again sort the values by marks C.

This only works correclty when , you have multiple values of marks A for a particular value of Marks C.

I hope this helps.

1 Like

hey @ajaysiddartha ,
I guess your doubt is now resolved.
So i would request kindly mark this doubt as resolved in your course’s doubt section and also to provide your valuable feedback as it would help us to improve our platform.

THank You and Happy Learning :slightly_smiling_face:.

1 Like

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.