Implement Miller Robin Primality test