Gravity weakens as you get farther away from surface, so the number of molecules decreases with altitude. Density decreases with altitude. Even though we can't feel the constant bombardment of air, the push of tiny molecules, we can detect rapid changes. Ears popping - air collisions outside the ear drum lessen. Ear popping, occurs as the molecules on the inside and outside equalize.
Pressure is force per unit area.
The pressure at any level in the atmosphere may be measured in terms of the total weight of the air above any point - atmospheric pressure. Pressure always decreases with altitude. Blow up a balloon - the number of molecules, and the speed, colliding against the sides determines the air pressure inside. I had to work to blow up the balloon. Which brings us to the definition of energy, which is the ability or capacity to do work on some form of matter.