use quantity to better show refactoring technique