Acids and Bases : The Basics
The most important thing for you to recognize is that almost ALL acid base questions are about equilibrium.
Where does Ka come from? From the equilibrium from NH4+, an acid, and NH3, its conjugate base:
And Kb comes from the equilibrium between a base and its conjugate acid: