Predict the output
py_list = ['E', 'X', 'C', 'E', 'L', ]
py_tuple = ('e', 'x', 'c', 'e', 'l')
slice_object = slice(-1, -4, -1) 
print(py_list[slice_object])  
slice_object = slice(-1, -5, -2)
print(py_tuple[slice_object]) 

Posted on by