Prove that if x and y are integers such that $x \equiv 3 \pmod{12}$ and $y \equiv 7\pmod{18}$, then $x + y \equiv 4\pmod6$
I tried making the equations into algebraic equations. So,
$x\equiv3\pmod{12}$ becomes $x=3+12p$ for $p\in \mathbb{Z}$
$y\equiv7 \pmod{18}$ becomes $y = 7 + 18q$ for $q \in \mathbb{Z}$
Then, $3+12p+7+18q=4+6k$ for some $q \in \mathbb{Z}$
Then I simplified it: $6p + 3q = k-1$
This is as far as I did.
Can anyone help me in solving this problem? I am confused. Thank you so much in advance.