There are a few remedies to this. 1. Add lots of fiber to your diet 2. Drink lots of water 3. Exercise - (walking is OK) 4. Mellon (high water content). 5. Grapes (high water content). 6. Stool softness (take max daily) 7. If these don't work, you can try OTC laxatives. Try the non-stimulant first, then switch to stimulant if those don't work. Stimulant laxitives can give you severe cramps, so start with the non-stimulant ones. Miralax (stimulant) works really good. 8. Get you Dr. To prescribe a prescription strength laxative. They make some that are 1/4 the size of a skittles that'll clean you out in an hour!
Eating spicy food also works for some people, but it can also give you very bad stomach pain if you are severely constipated.
Don't allow yourself to go too long without going - you could rupture your bowels and possibly die. Once you get regular, get on stool softeners and stay on them so this doesn't happen again.