Question: How to find 8th nextprime

Hi Mapleprimes,

The nextprime(n) function will give the next prime, given n.

Suppose I want the 8th next prime so how can I find the 8 th next prime quickly?

I guess I could find the ones in between, but maybee there is a better way.

n  nextprime(n,8)

2          23

3          29

5          31

7          37

 

Please Wait...