remove duplicate of line 13
refactoring to findpair