refactors tens