Find a therapist
There are lots of reasons you might be having this pattern of behavior. Without know how old you are, if these are new behaviors or longstanding ones, and what else is involved, e.
or drugs, no one can give a firm answer. It obviously bothers you--and should--so ask your primary care doctor for a referral to a therapist
to explore what is going on.