Since $|X_n| \leq Y$ a.s. for all $n$, we have that $\mathcal{P}\left(\bigcap_{n=1}^{\infty}\{|X_n|\leqslant Y\}\right) =1$
So now the solution asses that: $$\textstyle\mathcal{P}\left(\bigcap^\infty_{n=1}\{|X_n|\leqslant Y\}\right)=1=\mathcal{P}\big(\sup\{|X_n|\leqslant Y\}\big)$$
and clearly, the $\,\sup|X_n|\leqslant Y$ almost surely.
What is not clear to me and so my doubt is: Why can I rewrite the intersection as the supremum?
There is something wrong with the notation.
The following statements are equivalent:
This makes us conclude that:$$\bigcap_{n=1}^{\infty}\{|X_n|\leq Y\}=\{\sup_{n\in\mathbb N_+}|X_n|\leq Y\}$$The RHS does not agree with the expression in your question.
I am not quite familiar with expressions like $$\sup_{i\in I}A_i$$where ever $A_i$ is a set.
It can only be meaningful if there is an order on these sets.
Inclusion for instance, but then I would prefer "union" above "sup".