Artificial intelligent assistant

Is it true in general that $E_Z(E(Y\mid X, Z)) = E(Y\mid X)$ in that conditioning variables can be removed one by one? I am wondering if it is generally the case that $$ E_Z(E(Y\mid X, Z)) = E(Y\mid X) $$ in that conditioning variables can be removed one by one? I know that $$ E(E(Y\mid X, Z)\mid X) = E(Y\mid X) $$ is generally true, but can one selected which variables that are being conditioned on to marginalize over?

I think you are right. Here is my proof.

\begin{align} E(Y|X) & = \sum_{y} y P(Y=y|X) \\\ & = \sum_{y} \sum_z y P(Y=y,Z=z|X) \\\ & = \sum_{y} \sum_z y P(Y=y| Z=z,X) P(Z) \\\ & = E_z \left[\sum_{y} y P(Y=y| Z=z,X) \right] \\\ & = E_z \left[E(Y|Z,X) \right] \end{align}

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy 93e62592c2b4a5413e69eb78809d5fcc