How far to nearest/next prime?
Is there is metric to know how far we are from the nearest prime number. For example if my number is 38, then we are 3 numbers away from 41?
If such a metric doesn't exist, is there an upper bound saying that we must find a prime number before (say) the next 300 numbers?
For concrete bounds on prime gaps that improve upon "Bertrand's postulate", which (in a slightly weakened form) states:
$$ \forall n \ge 3 \;\exists p \text{, a prime s.t. } n < p < 2n $$
see a brief summary on the Prime Pages. In particular:
$$ \forall n \ge n_0 \;\exists p \text{, a prime s.t. } n < p < (1+\epsilon) n $$
holds for $\epsilon = 1/16597$ and $n_0 = 2010760$, proved by Schoenfeld in 1976. The citation given is to P. Ribenboim's The new book of prime number records, 3rd edition (Springer-Verlag, 1995). This has surely been improved upon as far as reducing $\epsilon \gt 0$.
Added: Pierre Dusart has proven concrete bounds of the form:
$$ \forall n \ge n_0 \;\exists p \text{, a prime s.t. } n < p < (1+e(n)) n $$
where $e(n)$ tends to zero as $n\to \infty$. In this arXiv.org paper from 2010 he shows that we can take $n_0 = 396738$ and the function:
$$ e(n) = \frac{0.04}{\ln^2 n} $$