As usual, for historical reasons we have more than one way to characterize an electron state in an atom. We can do it using the 4 quantum numbers, or we can use the notion of shells and subshells. A shell consists of all those states with the same value of n, the principal quantum number. A subshell groups all the states within one shell with the same value of l, the orbital quantum number.
The subshells are usually referred to by letters, rather than by the value of the orbital quantum number. The letters s, p, d, f, g, and h stand for l values of 0, 1, 2, 3, 4, and 5, respectively. Using these letters allows us to use a shorthand to denote how many electrons are in a subshell; this is useful for specifying the ground state (lowest energy state) of a particular atom.
The ground state configuration for oxygen, for instance, can be written as :
1s2 2s2 2p4
This means that the lowest energy configuration of oxygen, with 8 electrons, has two electrons in the n=1 s-subshell, two in the n=2 s-subshell, and four in the n=2 p-subshell.
Potassium (Z = 19) has an interesting ground state configuration:
1s2 2s2 2p6 3s2 3p6 4s1
That's interesting because there is a d-subshell in the n = 3 shell, but instead of the last electron going into that subshell it goes into the s-subshell of the n=4 shell. It does this to minimize the energy: the 4s subshell is at a lower energy than the 3d subshell.