The time period of spring block system is given by T=2πkm.
In both the cases springs are connected in parallel,
In case 1: keq=2k and total mass is 3m. Therefore,
T1=2πkeq(3m)=2π2k(3m)
In case 2:keq=3k and total mass is m. Therefore,
T2=2π3k(m)
⇒T2T1=29=23