Home > other >  The list of
The list of

Time:09-19

Excuse me somebody know why

CodePudding user response:

Sort the return value is None,
If you use sorted the return value is the sorted list,

CodePudding user response:

A=,4,2 [1]
A.s ort ()
Print (a)
B=[31] 1
B=sorted (b)
Print (b)


Output:
[1, 2, 4]
[1, 2, 3]

CodePudding user response:

There is no return value x.s ort
It is ok to use directly
  • Related