[::-1] ,this is an example of slice notation and helps to reverse the sequence with the help of indexing.
[Start,stop,step count]
Let’s understand with an example of an array:
import array as arr
Array_d=arr.array('i',[1,2,3,4,5])
Array_d[::-1]          #reverse the array or sequence
Output: 5,4,3,2,1