Hi i'm new here... I have a quick questions that I hope everyone can help me with

So our normal BP is in a 30 gallon and the Mojave is still small and in a 10 gallon possibly moving into the 20 gallon this weekend. However, we have a 40 gallon breeder tank (36w16h18d)....... Since they are both young can we put a secure plexiglass divider in the 40 gallon and put the snakes in different sides, just treat it like 2 separate tanks? I know when they get older/bigger they will need a 30 to 40 each but for now do you think this would work?