Possible range of of values modulo p Considering:$$ a\equiv b(mod\ 35)$$
b can be equivalent to 0,1,2,3...34.
Now if I divide 35 to 5 and 7, I am getting the equivelnce(for example):
$$ a\equiv b(mod\ 5)$$ but now the possible values of b are less then 35, they are: 0,1,2,3,4. But if for example in the first term I have in which b is equal, for example to 22, that is within the possible range values of modulo 35. Now b excesses the possible values of the second term(0-4). Where is my missconception ?
 A: I could imagine that your confusion is due to the somewhat unusual meaning and usage of the notation $a\equiv b\pmod p$. We tend to equivocate between viewing it as an equality between residue classes in $\mathbb Z_p$ and viewing it as an equality between integers in $\mathbb Z$ that holds "up to multiples of $p$". Both interpretations are OK, but you seem to have gotten confused between the two.
If you view it as an equality of residue classes, $a\equiv b\pmod p$ is a shorthand notation for $[a]_p=[b]_p$, where $[n]_p$ denotes the residue class in $\mathbb Z_p$ that contains the integer $n$.
If you view it as an equality of integers "up to multiples of $p$", then $a\equiv b\pmod p$ says that there's some integer $k$ such that $a=b+kp$.
Note that in both of these views, $b$ is an integer, so the question of it "exceeding its range" doesn't come up.
If, however, you mix the views and think of the left-hand and right-hand sides of the equivalence directly as residue classes, as written, then your question arises. Note, however, that it arises in a somewhat more fundamental way than just in that $b$ exceeds a fixed "range" of values $0,1,2,3,4$. This range isn't even well-defined, since these are just five arbitrary (though often very convenient) representatives of the five residue classes modulo $5$; we could equally well choose $3,4,5,6,7$. If you keep the distinctions clear in your mind, this is never a problem, since there's never a reason why an integer should have to be one of an arbitrary set of representatives.
