As we know,
T = 2 \pi \sqrt{l\over g}
Time period is directly proportional to the square root of the length of the pendulum.
In the case when,
T1 : T2 = 2 : 1 ….. [Equation 1]
we know that,
T1 : T2 = √l1 : √l2 ……. [Equation 2]
So we get,
√l1 : √l2 = 2 : 1
Squaring both sides we get,
l1 : l2 = 4 : 1
Hence, ratio of lengths = 4 : 1