Using specified number of iterations for Rainbow