Skip to content · ⁨ข้ามไปยังเนื้อหา⁩

Above average · ⁨เกินค่าเฉลี่ย⁩

English

Above average

Two loops, one after the other: the first works out the average, the second keeps the numbers above it.

This joins two patterns you have already used, the running total and the filter. Solving a problem in stages like this is how most longer programs are built.

ไทย

สูงกว่าค่าเฉลี่ย

สองลูป, หนึ่งต่ออีกอัน: ตัวแรกคำนวณค่าเฉลี่ย, ตัวที่สองเก็บตัวเลขที่สูงกว่ามัน

นี่คือการรวมสองรูปแบบที่คุณเคยใช้แล้ว, ผลรวมสะสมและการกรอง. การแก้ปัญหาเป็นขั้นตอนเช่นนี้คือวิธีที่โปรแกรมยาวๆ ส่วนใหญ่ถูกสร้างขึ้น

Log in or create account · ⁨เข้าสู่ระบบหรือสร้างบัญชี⁩

IGCSE, A-Level & AP