If your ceiling needs a fresh coat, paint it first, before doing your walls. Try Ace Brand Simply Magic Ceiling Paint ($18, www.acehardware.com for store locations). The paint goes on light blue to let you see where you've applied it, then dries to a pure white in 24 hours.
Ask a paint store to tint the primer toward your finish color if you're using a dark color. Tinting the primer will reduce the number of coats you'll need for good coverage.
If you're painting on a humid day, do not leave the windows wide open, because the paint will take longer to dry. Instead, crack a window and turn a fan on to circulate air.