Please enable JavaScript.
Coggle requires JavaScript to display documents.
Pre-release material 2017 (TASK 1 (CONSTANTS: total_coach_cost, ticket…
Pre-release material 2017
TASK 1
CONSTANTS: total_coach_cost, ticket_price
VARIABLES: students, students_going
CALCULATIONS: expenses = total_coach_cost + (students - students FLOOR 10) x ticket_price
CALCULATIONS: income = (expenses / students) * students_going
CALCULATIONS: profit = income - expenses
Store number of students who sign up for trip
Validate number of students between 1 and 45
Ensure program copes with non numeric data for number of students
TASK 2
Loop for all students
Store student names in array
Store whether student has paid in array(s)
Validate whether student has paid (e.g. yes / no, true / false)
Count how many students have paid
TASK 3
Things to remember
between 1 and 45 students only
need meaningful variable names
use error messages for user feedback
prompt user to enter data