a = []
for i in range (100,200):
if i % 12==0:
a.append(i)
print(a[-1])
I get output as 192. But without index calling if I use sort function like
a = []
for i in range (100,200):
if i % 12==0:
a.append(i)
print(a.sort(reverse=True))
I get output as none. Just want to know why sort is not working ?