Initially, let the masses of the bodies be m1 and m2 and the separation between them be r.
The gravitational force acting between them is given by
F=Gm1m2r2
Now the mass of both the bodies is made 4 times. Let the new separation be r′.
As per the question, F′=2F
⇒G4m14m2r′2=2Gm1m2r2
⇒8r′2=1r2
⇒r′2=8r2
⇒r′=2√2r