Another tip about gaps, they do NOT always distribute themselves evenly along the various sections of track.
What I have found is if you try to fix your track in place, glued ballast, screwed down, etc, then gaps are important.
If you free float your track in ballast as the prototype railroads do, then assemble without gaps. This is one of the reasons I prefer free floating track.
When I started this hobby in 1999, the "common wisdom" was to screw track down every foot or less, and DCC would not work outdoors, and on and on.
Now many people use DCC outdoors, and 90% of everyone I know is free-floating ballast. The downside is you cannot use scale ballast as it washes away with 1:1 scale environment, 8" raindrops, etc.