Lucid Imaging Interview Question

Circular prime number Array rotation with conditions