I'm not sure what you mean by the five step plan, but to get the answer, just think about the clues.
(c = number of cats)
8 fewer dogs than cats can be written: c - 8
since we know how many dogs there are: c - 8 = 12
Now, just solve for the variable: c = 20
Hope I helped :)