H is less electronegative than carbon and F is more electronegative than carbon and thus Hydrogen has positive charge and Flourine has negative charge.
The oxidation state of H = +1
Oxidation state of F = -1
Let the oxidation state of C = 'x'
Since the molecule is neutral, the net charge is zero. Therefore,
1(x)+2(1)+2(-1)= 0
x = 0
Therefore, the oxidation state of Carbon is zero.