1994 AIME Problem 7

For certain ordered pairs (a, b) of real numbers, the system of equations

\begin{aligned} & a x+b y=1 \\ & x^{2}+y^{2}=50 \end{aligned}

has at least one solution, and each solution is an ordered pair (x, y) of integers. How many such ordered pairs (a, b) are there?