Skip to content

Commit 00a4d83

Browse files
authored
Merge pull request #868 from josemunozc/move-comment-description-to-lesson-1
moved comment description to first lesson
2 parents 94500b4 + c24f343 commit 00a4d83

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

_episodes/01-intro.md

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@ keypoints:
1414
- "Use `variable = value` to assign a value to a variable in order to record it in memory."
1515
- "Variables are created on demand whenever a value is assigned to them."
1616
- "Use `print(something)` to display the value of `something`."
17+
- "Use `# some kind of explanation` to add comments to programs."
1718
- "Built-in functions are always available to use."
19+
1820
---
1921

2022
## Variables
@@ -209,8 +211,12 @@ weight in kilograms is now: 65.0
209211
> ~~~
210212
> {: .output}
211213
>
212-
> ![Value of 65.0 with weight_kg label stuck on it, and value of 143.0 with weight_lb label
213-
stuck on it](../fig/python-sticky-note-variables-02.svg)
214+
> Everything in a line of code following the '#' symbol is a
215+
> [comment]({{ page.root }}/reference/#comment) that is ignored by Python.
216+
> Comments allow programmers to leave explanatory notes for other
217+
> programmers or their future selves.
218+
>
219+
> ![Value of 65.0 with weight_kg label stuck on it, and value of 143.0 with weight_lb label stuck on it](../fig/python-sticky-note-variables-02.svg)
214220
>
215221
> Similar to above, the expression `2.2 * weight_kg` is evaluated to `143.0`,
216222
> and then this value is assigned to the variable `weight_lb` (i.e. the sticky

_episodes/02-numpy.md

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ keypoints:
1717
- "Use `array[x, y]` to select a single element from a 2D array."
1818
- "Array indices start at 0, not 1."
1919
- "Use `low:high` to specify a `slice` that includes the indices from `low` to `high-1`."
20-
- "Use `# some kind of explanation` to add comments to programs."
2120
- "Use `numpy.mean(array)`, `numpy.max(array)`, and `numpy.min(array)` to calculate simple statistics."
2221
- "Use `numpy.mean(array, axis=0)` or `numpy.mean(array, axis=1)` to calculate statistics across the specified axis."
2322
---
@@ -410,11 +409,6 @@ maximum inflammation for patient 0: 18.0
410409
~~~
411410
{: .output}
412411
413-
Everything in a line of code following the '#' symbol is a
414-
[comment]({{ page.root }}/reference.html#comment) that is ignored by Python.
415-
Comments allow programmers to leave explanatory notes for other
416-
programmers or their future selves.
417-
418412
We don't actually need to store the row in a variable of its own.
419413
Instead, we can combine the selection and the function call:
420414

0 commit comments

Comments
 (0)