Megaprogram Example: Overview
General I/O-megamodule
- Input function takes as parameter a default data structure containing names, types and default values for expected input
Travel information:
- Computing all possible routes between two cities
- Computing the air and ground cost for each leg given a list of city-pairs and data about the goods to be transported
Two megamodules that offer equivalent functions for calculating optimal routes
- Optimum and BestRoute both calculate the optimum route given routes and costs
- Global variables: Optimization can be done for cost or for time