Add a function that finds factors