Think of the ratios: gears fit tooth to tooth, so when gear b runs 8 teeth past the point where the two gears interact, then gear a also runs 8 teeth through that interaction zone.
Now if gear b goes around once, then it has moved 8 of its teeth through the interaction zone, so that means that gear a has also moved 8 of its own teeth through there. What fraction of a's teeth is that? What fraction of a complete rotation is that?
Hope this helps,
Stephen and Penny