At a minimum, all in-ground pools shall be surrounded and enclosed by a four-foot-high fence structurally suitable to prevent direct access to the body of water in the pool. Such a fence shall not have openings, holes or gaps therein larger than four inches in width, or, if larger than four inches in width, no larger than four inches in length except for doors or gates; provided, however, that if a picket fence is erected or maintained, the horizontal dimensions shall not exceed four inches. A dwelling house or accessory building may be used as a part of such a fence.