1
0
mirror of https://github.com/satwikkansal/wtfpython synced 2024-11-24 03:54:25 +01:00

Change images source in notebook

This commit is contained in:
Vadim Nifadev 2024-10-15 17:25:56 +03:00
parent 4b3818a667
commit c3e7cc9bed

View File

@ -4,7 +4,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"<p align=\"center\"><img src=\"https://raw.githubusercontent.com/nifadyev/wtfpython/refs/heads/feature/%2374/add-dark-theme-and-alt-support-for-images/images/logo.svg\" alt=\"wtfpython logo.\"></p>\n",
"<img src=\"https://raw.githubusercontent.com/nifadyev/wtfpython/refs/heads/feature/%2374/add-dark-theme-and-alt-support-for-images/images/logo.svg\" alt=\"wtfpython logo.\" style=\"display=block; margin:auto\">\n",
"<h1 align=\"center\">What the f*ck Python! \ud83d\ude31</h1>\n",
"<p align=\"center\">Exploring and understanding Python through surprising snippets.</p>\n",
"\n",
@ -2947,11 +2947,11 @@
"\n",
"When we initialize `row` variable, this visualization explains what happens in the memory\n",
"\n",
"![image](/images/tic-tac-toe/after_row_initialized.png)\n",
"<img src=\"https://github.com/satwikkansal/wtfpython/blob/master/images/tic-tac-toe/after_row_initialized.svg\" alt=\"Shows a memory segment after row is initialized..\" style=\"display=block; margin:auto\">\n",
"\n",
"And when the `board` is initialized by multiplying the `row`, this is what happens inside the memory (each of the elements `board[0]`, `board[1]` and `board[2]` is a reference to the same list referred by `row`)\n",
"\n",
"![image](/images/tic-tac-toe/after_board_initialized.png)\n",
"<img src=\"https://github.com/satwikkansal/wtfpython/blob/master/images/tic-tac-toe/after_board_initialized.svg\" alt=\"Shows a memory segment after board is initialized..\" style=\"display=block; margin:auto\">\n",
"\n",
"We can avoid this scenario here by not using `row` variable to generate `board`. (Asked in [this](https://github.com/satwikkansal/wtfpython/issues/68) issue).\n",
"\n"