Proof that $\{x\in\Bbb Z\mid x=4p-1 \text{ for some }p\in\Bbb Z\}$ and $\{y\in\Bbb Z\mid y =4q-5 \text{ for some }q\in\Bbb Z\}$ are equal I have a homework question that asks the following:

$A=\{x\in\mathbb{Z}\mid x=4p-1 \text{ for some }p\in\mathbb{Z}\}$
$B=\{y\in\mathbb{Z}\mid y =4q-5 \text{ for some }q\in\mathbb{Z}\}$
Prove that $A = B$

I have tried the following:
Let   $D \subseteq  A $ | $ 1\leq p \leq 5 $ $= \left\{3,7,11,15,19\right\}$
Let $E \subseteq B$ | $ 1\leq q \leq 5$ $= \left\{-1, 3,7,11,15\right\}$
I can see that if I shifted D so that  $p = p-1$, $D = E$, and since $D \subseteq A$ and $E \subseteq B$, it shows that $A = B$. Would induction be the best way to prove this formally? If so, since there are two variables, $p \text{ and } q$, would I set both to zero for base case, or just one? Then for the induction step, would I set it for $p+1$ and $q+1$ ?
 A: You could show the double inclusion.
$$x \in A \implies x = 4p-1=4(p+1)-5 \implies x \in B.$$
$$y \in B \implies y = 4q-5=4(q-1)-1 \implies y \in A.$$
A: The simplest way to prove this would be to show that $4p - 1 = 4q - 5$ whenever $p-q=1$. That is, if $x \in A$ has a corresponding integer $p$ that ensures $x \in A$, then $x \in B$ for the corresponding integer $q=p+1$. Of course, a similar argument for the reverse applies.
After all, $A$ is essentially all of the integers $1$ below a multiple of four, and $B$ is all those $5$ below a multiple of four. But any integer which is $5$ below a multiple of four is also $1$ below a different multiple of four. Therefore they have to coincide.
A: You can't prove that by considering examples. 
One way is to show that $A\subseteq B$ and $B\subseteq A$.
Consider an element $x\in A$. Then, by definition, $x=4p-1$ for some integer $p$. Are you able to write $x=4q-5$, for some integer $q$? This would show that $x\in B$.
Complete the other inclusion.
A: Hint:
$B=\{y| y=4(q+1) -5,$ $q \in \mathbb{Z} \}$.
