Free account: track your progress — Sign up free

WAEC Computer Studies 2025 Theory — Question 6

Question 6 of 6 from the West African Examinations Council (WAEC) Computer Studies 2025 Theory paper, with the correct answer and a full explanation.

Advertisement

6. Write a program in QBASIC to calculate the total and average scores in five subjects taken by each of ten students in a class. The scores of the ten students should be read from the keyboard.

Model answer

10 CLS 20 FOR Student Number = 1 TO 10 30 Student Total Score = 0 40 PRINT "Student Number:"; Student Number 50 FOR Subject Number = 1 TO 5 60 INPUT "Enter score for subject "; Subject Number; ":"; Subject Score 70 Student Total Score = Student Total Score + Subject Score 80 NEXT Subject Number 90 Student Average Score = Student Total Score / 5 100 PRINT "Total Score:"; Student Total Score 110 PRINT "Average Score:"; Student Average Score 120 NEXT Student Number 130 END

Advertisement

Sign up free to unlock

  • Score tracking
  • Practice history
  • Saved questions
  • Progress dashboard
  • Personalized sessions
  • Weak-topic breakdown

…and/or go further with premium services and No Ads.