Skip to content

Commit

Permalink
Merge pull request #140 from pyconjp/ISSHA-2562-python310
Browse files Browse the repository at this point in the history
ISSHA-2562 update python version
  • Loading branch information
takanory committed May 13, 2022
2 parents 22af697 + 652afa9 commit a6f59fe
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 17 deletions.
26 changes: 13 additions & 13 deletions source/textbook/1_install.rst
Original file line number Diff line number Diff line change
Expand Up @@ -53,22 +53,22 @@ macOSの場合
-----------
macOSでPythonを利用する場合は、Pythonの公式サイトで配布されているビルド済みのパッケージをインストールします。

「 `Python Release Python 3.9.9 <https://www.python.org/downloads/release/python-399/>`_ 」をブラウザで開きます。
「 `Python Release Python 3.10.4 <https://www.python.org/downloads/release/python-3104/>`_ 」をブラウザで開きます。
以下をダウンロードして実行し、Pythonをインストールします。

- `macOS 64-bit universal2 installer <https://www.python.org/ftp/python/3.9.9/python-3.9.9-macos11.pkg>`_
- `macOS 64-bit universal2 installer <https://www.python.org/ftp/python/3.10.4/python-3.10.4-macos11.pkg>`_

詳しくはPythonの公式ドキュメントの「 `MacintoshでPythonを使う <https://docs.python.org/ja/3/using/mac.html>`_ 」を参考にしてください。

インストールが完了したらPythonのバージョンが3.9.9になっていることを確認します:numref:`check-version-mac`)。
インストールが完了したらPythonのバージョンが3.10.4になっていることを確認します:numref:`check-version-mac`)。

.. _check-version-mac:

.. code-block:: bash
:caption: Pythonのバージョンを確認
$ python3 -V
Python 3.9.9
Python 3.10.4
.. index::
single: Install; Windows
Expand All @@ -78,13 +78,13 @@ Windowsの場合

WindowsでPythonを利用する場合は、Pythonの公式サイトで配布されているWindowsインストーラを利用します。

「 `Python Release Python 3.9.9 <https://www.python.org/downloads/release/python-399/>`_ 」をブラウザで開きます。
「 `Python Release Python 3.10.4 <https://www.python.org/downloads/release/python-3104/>`_ 」をブラウザで開きます。
OSによって以下のいずれかのインストーラーをダウンロードし、ウィザードに従ってインストールします。

- 64ビット版: `Windows installer (64-bit) <https://www.python.org/ftp/python/3.9.9/python-3.9.9-amd64.exe>`_
- 32ビット版: `Windows installer (32-bit) <https://www.python.org/ftp/python/3.9.9/python-3.9.9.exe>`_
- 64ビット版: `Windows installer (64-bit) <https://www.python.org/ftp/python/3.10.4/python-3.10.4-amd64.exe>`_
- 32ビット版: `Windows installer (32-bit) <https://www.python.org/ftp/python/3.10.4/python-3.10.4.exe>`_

この時、「Add Python 3.9 to PATH」にチェックを入れておきましょう。自動的に必要な環境変数が設定されます(:numref:`windows-install`)。
この時、「Add Python 3.10 to PATH」にチェックを入れておきましょう。自動的に必要な環境変数が設定されます(:numref:`windows-install`)。

.. _windows-install:

Expand All @@ -96,19 +96,19 @@ OSによって以下のいずれかのインストーラーをダウンロード
.. index::
single: Install; Linux

インストールが完了したらPythonのバージョンが3.9.9になっていることを確認します:numref:`check-version-win`)。
インストールが完了したらPythonのバージョンが3.10.4になっていることを確認します:numref:`check-version-win`)。

.. _check-version-win:

.. code-block:: doscon
:caption: Pythonのバージョンを確認
C:\Users\user>python -V
Python 3.9.9
Python 3.10.4
Linux(Ubuntu Server)の場合
----------------------------
Ubuntu 20.04にはデフォルトでPython 3.8.10がインストールされています
Ubuntu 22.04にはデフォルトでPython 3.10.4がインストールされています
以下のコマンドでPythonのバージョンを確認します(:numref:`check-version`)。

.. _check-version:
Expand All @@ -117,7 +117,7 @@ Ubuntu 20.04にはデフォルトでPython 3.8.10がインストールされて
:caption: Pythonのバージョンを確認
$ python3 -V
Python 3.8.10
Python 3.10.4
注意事項
========
Expand All @@ -130,7 +130,7 @@ Pythonを起動した時に表示される文字をチェックして、下記
- Pythonのバージョン(3.8以上であること)
- Anacondaという文字が表示されないこと

インストールされていない場合は前述の手順でPython3.9.9のインストールを行ってください
インストールされていない場合は前述の手順でPython3.10.4のインストールを行ってください

まとめ
======
Expand Down
5 changes: 2 additions & 3 deletions source/textbook/2_intro.rst
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,7 @@ Pythonインタープリタ
:caption: Pythonインタープリタの起動
$ python3
Python 3.9.9 (v3.9.9:ccb0e6a345, Nov 15 2021, 13:06:05)
[Clang 13.0.0 (clang-1300.0.29.3)] on darwin
Python 3.10.4 (v3.10.4:9d38120e33, Mar 23 2022, 17:29:05) [Clang 13.0.0 (clang-1300.0.29.30)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>>
Expand Down Expand Up @@ -480,7 +479,7 @@ FizzBuzz はいろいろな方法で実装できます。もっと短く、わ
Pythonでは整数や文字列、リストなど多種多様な値を使うことができますが、これらを区別して扱うための仕組みがあります。この仕組みのことを ```` といいます。
型ごとにできることとできないことが定義されていて、それぞれの値は型のインスタンスになります。
数値の ``100`` は整数型(int)の値で、他の数値と演算することができます。
数値の ``100`` は整数型(int)の値で、他の数値と演算することができます。
また、ある値の型は他の抽象度が高い型のものとみなすことができるものもあります。
たとえば文字列やリストの型は、それぞれ文字列型(str)のとリスト型(list)ですが、ほかに繰返し可能な型(シーケンス)ともいえます。
Expand Down
2 changes: 1 addition & 1 deletion source/textbook/6_venv.rst
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ Windowsの場合はスクリプトを実行します( :numref:`venv-activate-w
>>> import requests
>>> # requestsがインポートできる
``requests`` が ``env/lib/python3.9/site-packages`` 配下にインストールされます。
``requests`` が ``env/lib/python3.10/site-packages`` 配下にインストールされます。

またPythonパッケージの中にはコマンドとして実行可能なファイルが含まれている場合があります。それらのファイルは ``env/bin`` 配下にインストールされます。

Expand Down

0 comments on commit a6f59fe

Please sign in to comment.