Skip to content

Commit b9b503a

Browse files
committed
Duck types
1 parent ec203fd commit b9b503a

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1138,10 +1138,10 @@ class MyAbcSequence(collections.abc.Sequence):
11381138
return self.a[i]
11391139
```
11401140

1141-
#### Table of provided methods:
1141+
#### Table of the methods that each (duck) type provides:
11421142
```text
11431143
+------------+----------+------------+----------+--------------+
1144-
| | iterable | collection | sequence | abc.Sequence |
1144+
| | Iterable | Collection | Sequence | abc.Sequence |
11451145
+------------+----------+------------+----------+--------------+
11461146
| iter() | yes | yes | yes | yes |
11471147
| len() | | yes | yes | yes |

index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1070,9 +1070,9 @@ <h3 id="collectionsabcsequence">Collections.abc.Sequence</h3>
10701070
<span class="hljs-function"><span class="hljs-keyword">def</span> <span class="hljs-title">__getitem__</span><span class="hljs-params">(self, i)</span>:</span>
10711071
<span class="hljs-keyword">return</span> self.a[i]
10721072
</code></pre>
1073-
<h4 id="tableofprovidedmethods">Table of provided methods:</h4>
1073+
<h4 id="tableofthemethodsthateachducktypeprovides">Table of the methods that each (duck) type provides:</h4>
10741074
<pre><code class="text language-text">┏━━━━━━━━━━━━┯━━━━━━━━━━┯━━━━━━━━━━━━┯━━━━━━━━━━┯━━━━━━━━━━━━━━┓
1075-
┃ │ iterablecollectionsequence │ abc.Sequence ┃
1075+
┃ │ IterableCollectionSequence │ abc.Sequence ┃
10761076
┠────────────┼──────────┼────────────┼──────────┼──────────────┨
10771077
┃ iter() │ ✓ │ ✓ │ ✓ │ ✓ ┃
10781078
┃ len() │ │ ✓ │ ✓ │ ✓ ┃

parse.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ const DIAGRAM_5_B =
142142

143143
const DIAGRAM_6_A =
144144
'+------------+----------+------------+----------+--------------+\n' +
145-
'| | iterable | collection | sequence | abc.Sequence |\n' +
145+
'| | Iterable | Collection | Sequence | abc.Sequence |\n' +
146146
'+------------+----------+------------+----------+--------------+\n' +
147147
'| iter() | yes | yes | yes | yes |\n' +
148148
'| len() | | yes | yes | yes |\n' +
@@ -152,7 +152,7 @@ const DIAGRAM_6_A =
152152

153153
const DIAGRAM_6_B =
154154
'┏━━━━━━━━━━━━┯━━━━━━━━━━┯━━━━━━━━━━━━┯━━━━━━━━━━┯━━━━━━━━━━━━━━┓\n' +
155-
'┃ │ iterablecollectionsequence │ abc.Sequence ┃\n' +
155+
'┃ │ IterableCollectionSequence │ abc.Sequence ┃\n' +
156156
'┠────────────┼──────────┼────────────┼──────────┼──────────────┨\n' +
157157
'┃ iter() │ ✓ │ ✓ │ ✓ │ ✓ ┃\n' +
158158
'┃ len() │ │ ✓ │ ✓ │ ✓ ┃\n' +

web/script_2.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ const DIAGRAM_5_B =
110110

111111
const DIAGRAM_6_A =
112112
'+------------+----------+------------+----------+--------------+\n' +
113-
'| | iterable | collection | sequence | abc.Sequence |\n' +
113+
'| | Iterable | Collection | Sequence | abc.Sequence |\n' +
114114
'+------------+----------+------------+----------+--------------+\n' +
115115
'| iter() | yes | yes | yes | yes |\n' +
116116
'| len() | | yes | yes | yes |\n' +
@@ -120,7 +120,7 @@ const DIAGRAM_6_A =
120120

121121
const DIAGRAM_6_B =
122122
'┏━━━━━━━━━━━━┯━━━━━━━━━━┯━━━━━━━━━━━━┯━━━━━━━━━━┯━━━━━━━━━━━━━━┓\n' +
123-
'┃ │ iterablecollectionsequence │ abc.Sequence ┃\n' +
123+
'┃ │ IterableCollectionSequence │ abc.Sequence ┃\n' +
124124
'┠────────────┼──────────┼────────────┼──────────┼──────────────┨\n' +
125125
'┃ iter() │ ✓ │ ✓ │ ✓ │ ✓ ┃\n' +
126126
'┃ len() │ │ ✓ │ ✓ │ ✓ ┃\n' +

0 commit comments

Comments
 (0)