# How to change a text into a math operator?

For example, I write \max_{\forall n}, this results in \forall n to be underneath \max.

But \textsf{max} is so much cuter than \max.

I want to write \textsf{max}_{\forall n} and preserve the appearance as before.

But I am thrown an error:

\textsf{max} is not a math operator.

Is there anyway of changing \textsf{max} into a math operator?

In \displaystyle, the subscript goes under the operator.

\documentclass{article}
\usepackage{amsmath}
\DeclareMathOperator*{\sfmax}{\mathsf{max}}
\parskip 1ex
\begin{document}
$y = \sfmax_{\forall n} A_n$

$\displaystyle y = \sfmax_{\forall n} A_n$

$\scriptstyle y = \sfmax_{\forall n} A_n$
\end{document}