Create Generic Prime Solver