In[23]:=
Prime[ 5]
Out[23]=
11
In[24]:=
PrimePi[ %]
Out[24]=
5
Here, Prime[n] returns the nth prime and PrimePi[x] returns the number of
primes less than or equal to x.
The use of % and %n in expressions should be used very carefully since %
refers to
the last computed output and not the one right above the current expression.
If you
do another computation between using % and output you want to refer to, then
you will
get incorrect results.
Up to Tutorial