結果 : how to write custom sort function in python