Let ρ= resistivity of the material of wire 
r= radius of wire ∴ Resistance of 1 m wire is R=πr2ρ {∵R=Aρl} Let ε=emf of the cell in first case. All the cells are connected in series. So heat is msΔT=R(106)2t In 2nd case Resistance of some wire of length 2 m is : R′=πr2ρ(2)=πr22ρ=2R and then heat is : (2 m)SΔT=2R(nε)2t From eq. (i) and (ii) 200n2⇒n2=2=400⇒n=20