The rope vibrates every 0.5 s: it means that its period is
[tex] T=0.5 s [/tex]
The frequency of an oscillation is equal to the reciprocal of the period:
[tex] f=\frac{1}{T} [/tex]
Therefore, if we substitute T=0.5 s in the formula, we get:
[tex] f=\frac{1}{0.5 s}=2 Hz [/tex]