Skip to content
This repository was archived by the owner on Aug 11, 2023. It is now read-only.

Commit c717cec

Browse files
committed
Update access
1 parent fe99b48 commit c717cec

File tree

2 files changed

+20
-3
lines changed

2 files changed

+20
-3
lines changed

lessons/python/modules/numpy/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,6 @@
2727
- Filter
2828
- [Where](numpy_filter_values.py)
2929
- Access
30-
- One Row
31-
- One Column
32-
- Box
30+
- [One Row](numpy_access_one_row.py)
31+
- [One Column](numpy_access_one_column.py)
32+
- [Box](numpy_access_range.py)
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import numpy as np
2+
3+
L = [
4+
[1, 2, 3, 4, 5],
5+
[1, 2, 3, 4, 6],
6+
[1, 2, 3, 4, 7],
7+
[1, 2, 3, 4, 8],
8+
]
9+
10+
N = np.array(L)
11+
12+
13+
print(N[1])
14+
print(N[1, :])
15+
print(N[1, :3])
16+
print(N[1, 2:])
17+
print(N[1, 1:3])

0 commit comments

Comments
 (0)