Let $X_i$ be i.i.d. uniform random variables in $[0,\theta]$, for some $\theta>0$ and let $M_n =\max(X_i)$.
We have to find an interval $I$ of the form $I=[M_n,M_n+c]$, that does not depend on $\theta$ and such that $P[I\ni \theta]\to .95$ as $n \to\infty $.
Now, I calculated the CDF of $M_n$ which is $$F_{M_n}(y) = \begin{cases} 0 & \, \text{if} \ y < 0\\ \frac{y^n}{\theta^n} & \, \text{if} \ 0\leq y \leq \theta\\ 1 & \, \text{if} \ y > \theta \end{cases}$$
Now, after some simple calculations, we get, $E[M_n] = \frac{n\theta}{n+1}$ and $\sigma_{M_n} = \frac{\theta}{n+1}\sqrt{\frac{n}{n+2}}$
So, $\frac{M_n-\frac{n\theta}{n+1}}{\frac{\theta}{n+1}\sqrt{\frac{n}{n+2}}} \sim N(0, 1) $ by CLT.
Now, $P(-z_{\alpha/2} \leq \frac{M_n-\frac{n\theta}{n+1}}{\frac{\theta}{n+1}\sqrt{\frac{n}{n+2}}} \leq z_{\alpha/2}) = 1 - \alpha$ , where $\alpha = 0.05$
But I don't think this will give an interval of the form $I=[M_n,M_n+c]$. I mean how can I get the above equation in the form of $P(M_n \leq \theta \leq M_n + c) = 1 - \alpha$ for some $c$?
Thanks!
EDIT 1 : The above calculation is totally wrong as mentioned by StubbornAtom. I corrected myself and did the problem in a different way. Please see the next EDIT.
EDIT 2 : We have to use the fact that $Z_n = n(1-\frac{M_n}{\theta})$ converges in distribution to an exponential random variable with parameter $1$.
So, $Z_n$ has approximately Exp$(1)$ distribution for large $n$.
Now, $P(0\leq Z_n \leq k_{\alpha}) = 1 -\alpha$, where $k_{\alpha}$ is such that $P(Z_n\geq k_{\alpha}) = \alpha$ where $\alpha = 0.05$.
And this ultimately gives us the following condition $$P \bigg(M_n \leq \theta \leq \frac{M_n}{1-\frac{k_{\alpha}}{n}}\bigg) = 0.95$$ where $k_{\alpha}$ comes out to be $2.9957$. So the required interval that I am getting is $I = [M_n, \frac{M_n}{1-\frac{k_{\alpha}}{n}}]$ but this is still not the required form. What should I do now?
Outline:
(1) The maximum $W$ of $n$ independent random variables from $\mathsf{Unif}(0,1)$ has $W \sim \mathsf{Beta}(n-1, 1),$ which can be proved by looking at the CDF $F_W(w)$ of $W.$
(2) Then one can show that a confidence interval for $\theta$ based on the maximum $W$ of $n$ random observations from $\mathsf{Unif}(0,\theta)$ arises from $P(W < \theta < W/\alpha^n) = 1 - \alpha.$ for $0 < \alpha < 1).$ (See this Wikipedia page.)
Verification: Here is a simulation in R to illustrate the case where $n=20, \theta = 10, \alpha=.05,$ so that we can see what fraction of 100,000 such 95% confidence intervals actually covers $\theta.$