File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -1206,7 +1206,8 @@ class MyCollection:
1206
1206
1207
1207
### Sequence
1208
1208
* ** Only required methods are len() and getitem().**
1209
- * ** Iter(), contains() and reversed() automatically work on any object that has getitem() defined.**
1209
+ * ** Iter() and contains() automatically work on any object that has getitem() defined.**
1210
+ * ** Reversed() automatically works on any object that has getitem() and len() defined.**
1210
1211
``` python
1211
1212
class MySequence :
1212
1213
def __init__ (self , a ):
Original file line number Diff line number Diff line change @@ -1121,7 +1121,8 @@ <h3 id="collection">Collection</h3>
1121
1121
< h3 id ="sequence "> Sequence</ h3 >
1122
1122
< ul >
1123
1123
< li > < strong > Only required methods are len() and getitem().</ strong > </ li >
1124
- < li > < strong > Iter(), contains() and reversed() automatically work on any object that has getitem() defined.</ strong > </ li >
1124
+ < li > < strong > Iter() and contains() automatically work on any object that has getitem() defined.</ strong > </ li >
1125
+ < li > < strong > Reversed() automatically works on any object that has getitem() and len() defined.</ strong > </ li >
1125
1126
</ ul >
1126
1127
< pre > < code class ="python language-python hljs "> < span class ="hljs-class "> < span class ="hljs-keyword "> class</ span > < span class ="hljs-title "> MySequence</ span > :</ span >
1127
1128
< span class ="hljs-function "> < span class ="hljs-keyword "> def</ span > < span class ="hljs-title "> __init__</ span > < span class ="hljs-params "> (self, a)</ span > :</ span >
You can’t perform that action at this time.
0 commit comments