Let $R$ and $S$ be a ring and two ring homomorphism $f:R \to S$ and $g:R \to S$. Show that $H = \{x \in R | f(x) = g(x)\}$ is subring of R.
My attempt:
Let $x,y \in H$. Then, $f(x)=g(x)$ and $f(y)=g(y)$. Now,
$f(x-y) = f(x)-f(y) = g(x)-g(y) \in H$
and
$f(xy) = f(x)f(y) = g(x)g(y) \in H$
Hence, $H$ is subring of R.
Am I right?
$H$ is non empty as $1_R\in R$ , $f(1_R)=1_S=g(1_R).$ Let $x,y \in H$. $f(x)=g(x),f(y)=g(y)\in H$, Now, $f(x)-f(y) = f(x-y)= g(x-y)\in H$ Thus closed under subtraction. and
$f(x)f(y) = f(xy) = g(xy) \in H$ ,closed under multiplication. Hence, $H$ is subring of R.