for i in range(5):, repeat 5 times, score = int(input("Enter score: ")), ask for a score and store it as a number, if score >= 40:, check if the score is a pass, pass_count = pass_count + 1, add 1 to the pass counter, if score >= 80:, check if the score wins a prize, prize_count = prize_count + 1, add 1 to the prize counter, print("Pass"), show the word Pass on the screen, print("Try again"), show the words Try again on the screen, print("Prize"), show the word Prize on the screen, indentation, shows which lines belong inside the loop or if statement, range(5), creates 5 loop turns: 0, 1, 2, 3 and 4, counter, a variable that keeps score.
0%
Python Match Up
共有
共有
共有
Paullivesey
さんの投稿です
コンテンツの編集
印刷
埋め込み
もっと見る
割り当て
リーダーボード
もっと表示する
表示を少なくする
このリーダーボードは現在非公開です。公開するには
共有
をクリックしてください。
このリーダーボードは、リソースの所有者によって無効にされています。
このリーダーボードは、あなたのオプションがリソースオーナーと異なるため、無効になっています。
オプションを元に戻す
マッチアップ
は自由形式のテンプレートです。リーダーボード用のスコアは生成されません。
ログインが必要です
表示スタイル
フォント
サブスクリプションが必要です
オプション
AI強化版:この活動にはAIによって生成されたコンテンツが含まれています。
詳細情報。
テンプレートを切り替える
すべてを表示
アクティビティを再生すると、より多くのフォーマットが表示されます。
オープン結果
リンクをコピー
QRコード
削除
自動保存:
を復元しますか?