Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
1.Make Entry
.This enables entering a new order.
.Input is a 3 tuple consisting of the time since
the order was placed, cooking time required
and expected home delivery time.
.An order ID is generated for each order
placed.
.An estimate of time needed for delivery is
given.
Implementation
The external interface accepts three queries
2. Make Enquiry
This enables a customer to receive an
estimate of how much longer will the delivery
take.
This estimate is provided against the order Id.
Implementation
The external interface accepts three queries
3. Next Order
The pizza maker is told which order he must
process next to achieve the average minimum
waiting time for his customers.
Functions used in the main
program
The while loop used at the end is the main
program. The following functions are used in
the while loop are:
makeEntry()
getNextPizzaId()
makeEnquiry(order_id)
calcApparentCT(ct, personal_waiting_time)
updateExpectedDT()
updateApparentCT()
updatePersonalWT(increment)