What is reversed?
The reversed class is used to create a reverse iterator from an object .
This object , must either implement the __getitem__
and the __len__
special methods . In this case reverse will create an iterator from
The reversed class is used to create a reverse iterator from an object .
This object , must either implement the __getitem__
and the __len__
special methods . In this case reverse will create an iterator from
In python , objects are abstraction of data , they have methods that work with data , and help us to manipulate it . If we take a look at a list , and see … Read More