A triatomic molecule can rotate about any of three co-ordinate axes.
The molecule of a triatomic gas has a tendency of rotating about any of three co-ordinate axes. So, it has 6 degrees of freedom, 3 translational and 3 rotational. At high enough temperature, a triatomic molecule has 2 vibrational degrees of freedom. But as temperature requirement is not given, so we answer simply by assuming triatomic gas molecule at room temperature.
Thus, f=6
(3 translational +3 rotational) at room temperature.