solutions update from 7dcb112

This commit is contained in:
rougier
2026-07-24 13:36:00 +00:00
committed by github-actions[bot]
parent 7dcb112f80
commit a3beca2d7f
4 changed files with 219 additions and 219 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -494,11 +494,11 @@ print(Z[index])
`hint: dtype` `hint: dtype`
```python ```python
Z = np.zeros(10, [ ('position', [ ('x', float, 1), Z = np.zeros(10, [ ('position', [ ('x', float),
('y', float, 1)]), ('y', float)]),
('color', [ ('r', float, 1), ('color', [ ('r', float),
('g', float, 1), ('g', float),
('b', float, 1)])]) ('b', float)])])
print(Z) print(Z)
``` ```
#### 52. Consider a random vector with shape (100,2) representing coordinates, find point by point distances (★★☆) #### 52. Consider a random vector with shape (100,2) representing coordinates, find point by point distances (★★☆)

View File

@@ -494,11 +494,11 @@ print(Z[index])
```python ```python
Z = np.zeros(10, [ ('position', [ ('x', float, 1), Z = np.zeros(10, [ ('position', [ ('x', float),
('y', float, 1)]), ('y', float)]),
('color', [ ('r', float, 1), ('color', [ ('r', float),
('g', float, 1), ('g', float),
('b', float, 1)])]) ('b', float)])])
print(Z) print(Z)
``` ```
#### 52. Consider a random vector with shape (100,2) representing coordinates, find point by point distances (★★☆) #### 52. Consider a random vector with shape (100,2) representing coordinates, find point by point distances (★★☆)

View File

@@ -2,7 +2,7 @@
"cells": [ "cells": [
{ {
"cell_type": "markdown", "cell_type": "markdown",
"id": "4a87d009", "id": "261c7cb9",
"metadata": {}, "metadata": {},
"source": [ "source": [
"# 100 numpy exercises\n", "# 100 numpy exercises\n",
@@ -18,7 +18,7 @@
}, },
{ {
"cell_type": "markdown", "cell_type": "markdown",
"id": "16b631f6", "id": "b0ffec6a",
"metadata": {}, "metadata": {},
"source": [ "source": [
"File automatically generated. See the documentation to update questions/answers/hints programmatically." "File automatically generated. See the documentation to update questions/answers/hints programmatically."
@@ -26,7 +26,7 @@
}, },
{ {
"cell_type": "markdown", "cell_type": "markdown",
"id": "8c00c264", "id": "30434163",
"metadata": {}, "metadata": {},
"source": [ "source": [
"Run the `initialise.py` module, then call a random question with `pick()` an hint towards its solution with\n", "Run the `initialise.py` module, then call a random question with `pick()` an hint towards its solution with\n",
@@ -36,7 +36,7 @@
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": null, "execution_count": null,
"id": "c5fa0b45", "id": "8f632d6c",
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [
@@ -46,7 +46,7 @@
{ {
"cell_type": "code", "cell_type": "code",
"execution_count": null, "execution_count": null,
"id": "6c4f9753", "id": "6cfc4341",
"metadata": {}, "metadata": {},
"outputs": [], "outputs": [],
"source": [ "source": [