According to most dating methods, pregnancy lasts approximately 280 days. Lunar months are considered to be roughly 28 days (4 weeks) — and 280 divided by 28 breaks into 10 approximate lunar months.
If you really want to get technical: A sidereal month is 27.32 days, a synodic month is 29.53 days, and an anomalistic month is 27.55 days. See why they decided to round?
Even with “normal” counting methods (”30 days hath September” and all that), every month would need to have 31.111 days for pregnancy to end when precisely 9 months have been completed. That means women usually go into the 10th month — but don’t complete it — during the course of your average, everyday, garden-variety pregnancy.
And if you really want to muddy the waters… If you’re basing your due date on a 28-day menstrual cycle, 14 of those days cover the time from your last period up to conception — so you’re not actually not pregnant at all. That brings the day count of actual gestation down to 266 days.