Two more molecules
In water and methane the outer atoms were hydrogen, which has no electrons to spare. These two molecules show what happens when the outer atoms carry lone pairs as well.
Hydrogen chloride
Chlorine is 2, 8, 7 and needs one electron; hydrogen has one to share. They share a single pair, and the chlorine atom keeps its remaining three pairs untouched.
Figure to be added
The chlorine atom now counts eight: six in its own three pairs and two in the shared pair. The hydrogen atom counts two, which is all it can hold.
Carbon tetrachloride
Carbon is four electrons short and chlorine one. Four chlorine atoms therefore satisfy one carbon atom, each sharing a single pair with it.
Figure to be added
Twelve lone pairs sit around the outside of this molecule and take no part in holding it together. Only the four shared pairs are bonds.
Two questions, asked separately
For every atom in a molecule, ask how many bonds it forms and how many lone pairs it keeps. The first follows from how far it is short of eight; the second is whatever valence electrons are left over.