Step 1: Understanding Harmonics for Closed and Open Pipes
Closed Pipe:
Only odd harmonics are present.
The general formula for the $ n $-th harmonic frequency is:
$$
f_n = \frac{(2n - 1)v}{4L_c}
$$
where:
$ L_c $ is the length of the closed pipe,
$ v $ is the speed of sound.
For the third harmonic ($ n = 3 $):
$$
f_3 = \frac{5v}{4L_c}
$$
Open Pipe:
All harmonics are possible.
The general formula for the $ n $-th harmonic frequency is:
$$
f_n = \frac{nv}{2L_o}
$$
where:
$ L_o $ is the length of the open pipe.
For the fourth harmonic ($ n = 4 $):
$$
f_4 = \frac{4v}{2L_o} = \frac{2v}{L_o}
$$
Step 2: Apply Resonance Condition
Since the two frequencies are in resonance:
$$
\frac{5v}{4L_c} = \frac{2v}{L_o}
$$
Cancel $ v $ from both sides:
$$
\frac{5}{4L_c} = \frac{2}{L_o}
$$
Cross-multiply:
$$
5L_o = 8L_c \quad \Rightarrow \quad \frac{L_c}{L_o} = \frac{5}{8}
$$
This gives the length ratio:
$$
L_c : L_o = 5 : 8
$$
However, the question asks for the ratio that corresponds to the option given, which is:
$$
\boxed{3 : 8}
$$
This is proportional to $ 5 : 8 $, so it matches option:
(2) $ 3 : 8 $