The R, for the majority of probability distributions, there are four functions, called d, p, q, r, ( e.g., dnorm, pnorm, qnorm, rnorm) giving you density (d), the cumulative distribution function (p, since the result is the probability) and its inverse ( q, since the result is a quantile) and r for a sample from the distribution.
qgamma.