They produce the same results.
>>> for i in range(10, -1, -1):
... print(i)
...
10
9
8
7
6
5
4
3
2
1
0
contrasted with:
>>> for i in reversed(range(0, 10 + 1):
... print(i)
...
10
9
8
7
6
5
4
3
2
1
0
From what I understand, Python3's range
creates a generator rather than storing the whole range in memory. reversed
likewise generates its values one at a time, I think. Is there any reason to use one over the other?