BECE Aggregate Calculator
// Calculate core subjects total (English, Maths, Science) let coreTotal = english + math + science;
// Calculate elective subjects total (ICT, French, Home Economics) let electiveTotal = ict + french + homeEconomics;
// Calculate the aggregate let aggregate = coreTotal + electiveTotal;
// Display result document.getElementById('result').textContent = "Your BECE Aggregate is: " + aggregate;
// Qualification check let message = aggregate <= 30 ? "Congratulations! You qualify for school placement." : "Unfortunately, your aggregate is above 30, which may affect your school placement chances."; document.getElementById('message').textContent = message; }