First attempt
Added only prime restriction