The bigger number
このページには最新のブラウザ(SharedArrayBuffer対応)が必要です。Chrome、Edge、Firefox、Safariを最新バージョンに更新してください。
これはまだ完了していないレッスンの先にある内容です。まずはそのレッスンを済ませてください:
Python Basics · 判断の作成 →
English
The bigger number
Read two whole numbers a and b, one per line, with int(input()) (for example 8 and 15). Store the bigger one in biggest and print it. If they are equal, print equal instead.
A branch can set a variable, not only print. Give biggest a value on every path that prints it, or one path leaves it undefined and Python says NameError. Test the tie first: max alone cannot tell you that the two numbers were equal.
難易度 1/5 · 100 コイン + 今日初回達成時の小ボーナス
Read two whole numbers a かつ b, one per line, with int(input()). Store the bigger one in biggest and print it. If they are equal, print equal instead.
実行ボタンをクリックして出力を確認してください。