more work on cs520 prog7