#f(x) = cos x/(1 - sin x) - sin x/(cos x) = # #= [cos^2 x - sin x(1 - sin x)]/(cos x(1 - sin x))#
The numerator results in: #(cos^2 x - sin x + sin^2 x) = 1 - sin x#,
because #sin^2 x + cos^2 x = 1#
Finally, #f(x) = (1- sin x)/(cos x(1 - sin x)) = 1/(cos x) = sec x#