Refactoring of addnumbers before testing