Finish the function · 関数を完成させる
This page needs a recent browser (with SharedArrayBuffer support). Please update Chrome, Edge, Firefox or Safari to the latest version. · このページには最新のブラウザ(SharedArrayBuffer対応)が必要です。Chrome、Edge、Firefox、Safariを最新バージョンに更新してください。
This one builds on a lesson you haven't finished yet. Do that lesson first: · これはまだ完了していないレッスンの先にある内容です。まずはそのレッスンを済ませてください:
Python Basics · Functions →
English
Finish the function
The def line is written. Add the one line inside it that gives back a + b.
a and b stand for whatever the caller passes in. Inside the function you use them as ordinary variables — the body is just normal code, indented under the def.
日本語
関数を完成させる
defの行は書かれています。a + bを返す1行をその中に追加してください。
aとbは呼び出し側が渡すものを表します。関数の内部では通常の変数として使います——本体は simply defの下にインデントされた通常のコードです。
The def line is written. Add the one line inside it that gives back a + b. · defの行は書かれています。a + bを返す1行をその中に追加してください。
Click Run to see the output here. · 実行ボタンをクリックして出力を確認してください。