Skip to content

Commit fa8fa9c

Browse files
committed
update tutorials
1 parent b9bd7ab commit fa8fa9c

File tree

4 files changed

+27979
-109
lines changed

4 files changed

+27979
-109
lines changed

CONTRIBUTING.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@
33
Contributions are welcome, and they are greatly appreciated! Every little bit
44
helps, and credit will always be given. You can contribute in the ways listed below.
55

6+
## Language
7+
8+
Please use gender-neutral forms and inclusive language.
9+
610
## Report Bugs
711

812
Report bugs using GitHub issues.

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
[![bckrlab.org](https://img.shields.io/badge/bckrlab.org-blue?style=flat)](https://bckrlab.org/dsc-tutorials/intro.html)
12
[![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/bckrlab/dsc-tutorials/HEAD)
23

34
# DSC Tutorials

dsc_tutorials/01_python-intro.ipynb

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,10 @@
106106
"source": [
107107
"[Python](https://en.wikipedia.org/wiki/Python_(programming_language)) is a programming language that was developed in 1991 by \"Benevolent dictator for life\" Guido van Rossum.\n",
108108
"\n",
109+
"<div style=\"text-align: center\">\n",
110+
" <img src=\"https://upload.wikimedia.org/wikipedia/commons/6/66/Guido_van_Rossum_OSCON_2006.jpg\" alt=\"Guido van Rossum\" width=\"25%\"/>\n",
111+
"</div>\n",
112+
"\n",
109113
"Python is:\n",
110114
"\n",
111115
"- **Interpreted**: Programs are executed line by line by an interpreter instead of being compiled into machine code first.\n",
@@ -175,7 +179,7 @@
175179
},
176180
{
177181
"cell_type": "code",
178-
"execution_count": 8,
182+
"execution_count": null,
179183
"id": "1e0cc47a",
180184
"metadata": {},
181185
"outputs": [],
@@ -221,7 +225,7 @@
221225
"\n",
222226
" def action(self):\n",
223227
" # implement selecting a random action\n",
224-
" raise NotImplementedError()\n",
228+
" raise NotImplementedError(\"TODO\")\n",
225229
"\n",
226230
"def rock_paper_scissors(agent_a, agent_b):\n",
227231
" choice_a = agent_a.get_choice()\n",
@@ -231,7 +235,7 @@
231235
" agent_b.observe(choice_a)\n",
232236
"\n",
233237
" # implement game logic\n",
234-
" raise NotImplementedError"
238+
" raise NotImplementedError(\"TODO\")"
235239
]
236240
},
237241
{
@@ -295,23 +299,24 @@
295299
},
296300
{
297301
"cell_type": "code",
298-
"execution_count": 21,
302+
"execution_count": 1,
299303
"id": "c539f499-e744-43b6-b6fc-eedc5c793f5b",
300304
"metadata": {},
301305
"outputs": [
302306
{
303307
"name": "stdout",
304308
"output_type": "stream",
305309
"text": [
306-
"Collecting pyjokes\n",
307-
" Downloading pyjokes-0.8.3-py3-none-any.whl.metadata (3.4 kB)\n",
308-
"Downloading pyjokes-0.8.3-py3-none-any.whl (47 kB)\n",
309-
"Installing collected packages: pyjokes\n",
310-
"Successfully installed pyjokes-0.8.3\n"
310+
"Requirement already satisfied: pyjokes in /home/bjarne/miniconda3/envs/dsc-tutorials/lib/python3.12/site-packages (0.8.3)\n",
311+
"^C\n",
312+
"\u001b[31mERROR: Operation cancelled by user\u001b[0m\u001b[31m\n",
313+
"\u001b[0m"
311314
]
312315
}
313316
],
314317
"source": [
318+
"# shell assignment syntax\n",
319+
"# ! in jupyter cells allows you to execute shell commands\n",
315320
"!pip install pyjokes"
316321
]
317322
},

0 commit comments

Comments
 (0)