shoplist = ['apple', 'mango', 'carrot', 'banans']
name = 'Dred'

print('Elem 0 - ', shoplist[0])
print('Elem 1 - ', shoplist[1])
print('Elem 2 - ', shoplist[2])
print('Elem 3 - ', shoplist[3])
print('Elem -1 - ', shoplist[-1])
print('Elem -2 - ', shoplist[-2])
print('Elem -3 - ', shoplist[-3])
print('Sybol 0 - ', name[0])

print('Elem 1 : 3 - ', shoplist[1:3])
print('Elem from 2 - ', shoplist[2:])
print('Elem 1: -1', shoplist[1:-1])
print('Elem all - ', shoplist[:])

print('Sybol 1:3 - ', name[1:3])
print('Sybol 2 to end - ', name[2:])
print('Sybol 1:-1 - ', name[1:-1])
print('Sybol all - ', name[:])