ls = list(range(10))
ls.reverse()
print(ls)
Why does this work in producing a list that counts backwards from 9 not but not this:
ls = list(range(10)).reverse()
print(ls)
These last two lines prints this instead:
None
Shouldn't they be the same thing?