Follow box counts through helper calls

A delivery program combines two orders and removes rejected boxes before recording a van's load. Consider this Python code:


Python
def log_load(van, boxes):
    print(van, boxes)

def prepare_load(packed, damaged):
    log_load("Blue", packed - damaged)

def combine_orders(morning, afternoon, rejected):
    prepare_load(morning + afternoon, rejected)

combine_orders(28, 37, 6)


Determine the value received by packed in prepare_load and the value received by boxes in log_load. Give both quantities in boxes, as exact integers with zero decimal places.

Your answers

Create a free account to get started

Unlock full course notes by signing up

  • Video lessons taught by top educators
  • Practice questions with guided solutions
  • Written review notes for reference
  • Expert answers anytime from course tutors

More Parameters and Arguments Questions: