This is LaTeX code:
[latex]
\max\{0,S_n-\overline{S}_n\}
[/latex]