Okay, don't panic. There are many things that could be going on.
First, you could have swimmer's ear. Do you submerge your head in water often or participate in any activities that involve swimming? When you swim, pressure from being underwater will push all the wax in your ear canal up against your eardrum, which causes temporary deafness.
Second, you use cotton swabs to clean your ears. Do NOT and I repeat, DO NOT stick those things in your ears, it also pushes wax against the eardrum. It makes sense to stick them in, but you're not supposed to. Inner-ear wax actually falls out by itself believe it or not, and cotton swabs were actually made to clean the curves on the outside of your ears, because those harbor lots of wax.
So how do you fix it? Go to a doctor and ask for ear drops. It's liquid that you just trickle into your ear canal and it dissolves the wax that you've probably impacted against your eardrum.
How is this mathematically possible
Taking a shower gets rid of lots of wax due to the water entering your ear. Other than that uhhh q-tips? Everyone and then I pull out a booger of wax but my ears have never been clogged wtf
You couldn't be more incorrect. Just like people who say water is good to moisten dry skin. WRONG.
EDIT: And before my methods and knowledge are questioned, I've had around 15 ear infections, half of those left me temporarily deaf, others left me in so much pain I threw convulsions. Do not put cotton swabs in your ears, ever.