4.1.12
Outline the pre- and post-conditions to a specified problem.
Teaching Note:
For example, cooking a dish for a meal.
All ingredients available before starting to cook.
A place to eat the food.
Sample Question:
JSR Notes:
Teaching Note Example
Teaching Note:
For example, cooking a dish for a meal.
So the point here is that it would be dumb to start cooking a dish for a meal if you didn't have the ingredients needed to make it, or if you didn't have a place to eat it after having made it. Much better to A. have pre-conditions, and B. check that those pre-conditions are met before launching in to the preparation of the meal.
Non-Computer Examples
IASAS Football Tournament:
Pre-conditions:
Post-Conditions:
Computer/Programming/Java Examples
Binary Search of Strings
Pre-conditions:
Post-Conditions: