yes that's a bit big for your size snake.easiest thing to do is put a divider in the 40 gal. tank.

you could use a piece of cardboard or plastic taped in place,as your snake grows you can increase the size of the enclosure.have fun !