Find Maximum of any discrete function (not necessarily a PDF)
Hint: Consider the ratio of successive terms $\dfrac{f(n)}{f(n-1)}$, for $n\ge 1$. (This ratio here equals $\dfrac{(n+1)^2}{2n^2}$.) Try and find for which values of $n$ we have $\color{blue}{\dfrac{f(n)}{f(n-1)} \ge 1}$. Can you see how to use this information to find which $n$ maximises $f(n)$?
Hint: Prove that $$\frac{(n+1)^2}{2^n}\le \frac{9}{4}$$ The equal sign holds if $$n=2$$ This is equivalent to $$(n+1)^2\le 9\cdot 2^{n-2}$$. You can prove this by induction.