I would like to print the current element, from the end, and the elements on its right.
This is my script:
lst = ["namaste", "hello", "ciao", "salut"]
for el, nxt in reversed(zip(lst, lst[1:]))
print(el, nxt)
unfortunately I am getting:
zip object is not reversible
I would like to get this result:
Ciao, Salut
Hello, Ciao
Namaste, Hello
- How can I do?