回答編集履歴
1
実行結果を追加
test
CHANGED
@@ -3,3 +3,17 @@
|
|
3
3
|
|
4
4
|
|
5
5
|
です。
|
6
|
+
|
7
|
+
|
8
|
+
|
9
|
+
```python
|
10
|
+
|
11
|
+
>>> l = [(0, 0, 0), (0, 1, 1), (0, 2, 2), (1, 0, 1), (1, 1, 2), (1, 2, 3)]
|
12
|
+
|
13
|
+
>>> lst = [e[-1] for e in l]
|
14
|
+
|
15
|
+
>>> print(lst)
|
16
|
+
|
17
|
+
[0, 1, 2, 1, 2, 3]
|
18
|
+
|
19
|
+
```
|