Skip to content

Commit 487111e

Browse files
authored
Merge pull request #52 from sikepuri-algorithm/manuscript
Manuscript
2 parents 5fc08b3 + d2ca46c commit 487111e

26 files changed

+880
-2
lines changed

.pre-commit-config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,12 @@ repos:
4343
rev: 1.5.3
4444
hooks:
4545
- id: nbqa-check-ast
46-
- id: nbqa-flake8
46+
# - id: nbqa-flake8
4747
- id: nbqa-isort
4848
- id: nbqa-mypy
4949
# - id: nbqa-pylint
5050
- id: nbqa-pyupgrade
51-
- id: nbqa-yapf
51+
# - id: nbqa-yapf
5252
- id: nbqa-autopep8
5353
# - id: nbqa-pydocstyle
5454
- repo: https://github.com/pre-commit/pre-commit-hooks

docs/index.mdx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,5 @@ Python やアルゴリズムについて簡単にまとめていこうかなと
3131
10/16 練習問題をさらに追加
3232

3333
10/23 第二週の分を執筆 [ここから](/docs/python/05function/)
34+
35+
10/30 第三週の分を執筆 [ここから](/docs/python/07for/)
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
{
2+
"nbformat": 4,
3+
"nbformat_minor": 2,
4+
"metadata": {},
5+
"cells": [
6+
{
7+
"metadata": {},
8+
"source": [
9+
"def factorial(n):\n",
10+
" product = 1\n",
11+
" for i in range(1, n + 1):\n",
12+
" product *= i\n",
13+
" return product\n",
14+
"\n",
15+
"\n",
16+
"print(factorial(10))"
17+
],
18+
"cell_type": "code",
19+
"outputs": [
20+
{
21+
"output_type": "stream",
22+
"name": "stdout",
23+
"text": [
24+
"3628800\n"
25+
]
26+
}
27+
],
28+
"execution_count": null
29+
}
30+
]
31+
}
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
{
2+
"nbformat": 4,
3+
"nbformat_minor": 2,
4+
"metadata": {},
5+
"cells": [
6+
{
7+
"metadata": {},
8+
"source": [
9+
"import math\n",
10+
"\n",
11+
"print(math.factorial(10))"
12+
],
13+
"cell_type": "code",
14+
"outputs": [
15+
{
16+
"output_type": "stream",
17+
"name": "stdout",
18+
"text": [
19+
"3628800\n"
20+
]
21+
}
22+
],
23+
"execution_count": null
24+
}
25+
]
26+
}
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
{
2+
"nbformat": 4,
3+
"nbformat_minor": 2,
4+
"metadata": {},
5+
"cells": [
6+
{
7+
"metadata": {},
8+
"source": [
9+
"for i in range(1, 11):\n",
10+
" print(i)"
11+
],
12+
"cell_type": "code",
13+
"outputs": [
14+
{
15+
"output_type": "stream",
16+
"name": "stdout",
17+
"text": [
18+
"1\n",
19+
"2\n",
20+
"3\n",
21+
"4\n",
22+
"5\n",
23+
"6\n",
24+
"7\n",
25+
"8\n",
26+
"9\n",
27+
"10\n"
28+
]
29+
}
30+
],
31+
"execution_count": null
32+
}
33+
]
34+
}
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
{
2+
"nbformat": 4,
3+
"nbformat_minor": 2,
4+
"metadata": {},
5+
"cells": [
6+
{
7+
"metadata": {},
8+
"source": [
9+
"for i in range(10):\n",
10+
" print(\"Hello!\")"
11+
],
12+
"cell_type": "code",
13+
"outputs": [
14+
{
15+
"output_type": "stream",
16+
"name": "stdout",
17+
"text": [
18+
"Hello!\n",
19+
"Hello!\n",
20+
"Hello!\n",
21+
"Hello!\n",
22+
"Hello!\n",
23+
"Hello!\n",
24+
"Hello!\n",
25+
"Hello!\n",
26+
"Hello!\n",
27+
"Hello!\n"
28+
]
29+
}
30+
],
31+
"execution_count": null
32+
}
33+
]
34+
}
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
{
2+
"nbformat": 4,
3+
"nbformat_minor": 2,
4+
"metadata": {},
5+
"cells": [
6+
{
7+
"metadata": {},
8+
"source": [
9+
"for i in range(1, 11):\n",
10+
" print(\"Hello!\")"
11+
],
12+
"cell_type": "code",
13+
"outputs": [
14+
{
15+
"output_type": "stream",
16+
"name": "stdout",
17+
"text": [
18+
"Hello!\n",
19+
"Hello!\n",
20+
"Hello!\n",
21+
"Hello!\n",
22+
"Hello!\n",
23+
"Hello!\n",
24+
"Hello!\n",
25+
"Hello!\n",
26+
"Hello!\n",
27+
"Hello!\n"
28+
]
29+
}
30+
],
31+
"execution_count": null
32+
}
33+
]
34+
}
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
{
2+
"nbformat": 4,
3+
"nbformat_minor": 2,
4+
"metadata": {},
5+
"cells": [
6+
{
7+
"metadata": {},
8+
"source": [
9+
"sum = 0\n",
10+
"for i in range(1, 101):\n",
11+
" sum += i\n",
12+
"print(sum)"
13+
],
14+
"cell_type": "code",
15+
"outputs": [
16+
{
17+
"output_type": "stream",
18+
"name": "stdout",
19+
"text": [
20+
"5050\n"
21+
]
22+
}
23+
],
24+
"execution_count": null
25+
}
26+
]
27+
}
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
{
2+
"nbformat": 4,
3+
"nbformat_minor": 2,
4+
"metadata": {},
5+
"cells": [
6+
{
7+
"metadata": {},
8+
"source": [
9+
"sum = 0\n",
10+
"for i in range(1, 1001):\n",
11+
" sum += i\n",
12+
"print(sum)"
13+
],
14+
"cell_type": "code",
15+
"outputs": [
16+
{
17+
"output_type": "stream",
18+
"name": "stdout",
19+
"text": [
20+
"500500\n"
21+
]
22+
}
23+
],
24+
"execution_count": null
25+
}
26+
]
27+
}
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
{
2+
"nbformat": 4,
3+
"nbformat_minor": 2,
4+
"metadata": {},
5+
"cells": [
6+
{
7+
"metadata": {},
8+
"source": [
9+
"for i in range(10):\n",
10+
" print(i)"
11+
],
12+
"cell_type": "code",
13+
"outputs": [
14+
{
15+
"output_type": "stream",
16+
"name": "stdout",
17+
"text": [
18+
"0\n",
19+
"1\n",
20+
"2\n",
21+
"3\n",
22+
"4\n",
23+
"5\n",
24+
"6\n",
25+
"7\n",
26+
"8\n",
27+
"9\n"
28+
]
29+
}
30+
],
31+
"execution_count": null
32+
}
33+
]
34+
}

0 commit comments

Comments
 (0)