The CFA Quantitative Methods book uses the following formula for finding the observation in a sorted list that corresponds to a given percentile $y$ in a set of observations of size $n$:
$(n + 1)\frac{y}{100}$
It defines percentile as follows: "Given a set of observations, the yth percentile is the value at or below which y percent of observations lie."
My question is, where does the $+ 1$ come from? I can see that if you wanted to ensure that all values are below a given percentile, it is useful. It also ensures the correct value for the median. But given the definition of percentile above, I would think it should be possible to have a hundredth percentile, which would be equal to the largest value. Is the "at or below" in conflict with the $+ 1$?
You answered your own question:
"I can see that if I use the first formula to calculate the 50th percentile, the +1 ensures I get the same answer as when I calculate the median."
That's a really important property for percentiles! One you should want.
Also, if you are fitting empirical data to some parametric curve, adding +1 allows for a "tail". Many curves you would fit to have infinite support, so if you did not add +1, you would be saying your last data point is at the 100%-tile, which is usually a bad assumption.