Writing programs (i.e., database software) should include subtotal and group print by
sorting the data
combining like fields
summarizing the data in the field
printing.